comparison cy_works/cqu.pxd @ 68:eb91fd5d49b3

minimally changed to get Cython Queue example working, Cython version
author Henry S Thompson <ht@inf.ed.ac.uk>
date Fri, 17 Jan 2025 15:43:56 +0000
parents
children
comparison
equal deleted inserted replaced
67:eb4be545fcc8 68:eb91fd5d49b3
1 cdef extern from "c-algorithms/src/queue.h":
2 ctypedef struct Queue:
3 pass
4 ctypedef void* QueueValue
5
6 Queue* queue_new()
7 void queue_free(Queue* queue)
8
9 int queue_push_head(Queue* queue, QueueValue data)
10 QueueValue queue_pop_head(Queue* queue)
11 QueueValue queue_peek_head(Queue* queue)
12
13 int queue_push_tail(Queue* queue, QueueValue data)
14 QueueValue queue_pop_tail(Queue* queue)
15 QueueValue queue_peek_tail(Queue* queue)
16
17 bint queue_is_empty(Queue* queue)