blob: de6d58a99314dca6d43ab6f190425ccfa626d152 (
plain)
1
2
3
4
5
6
7
8
9
10
|
from cython.cimports import cqueue
@cython.cclass
class Queue:
_c_queue = cython.declare(cython.pointer(cqueue.Queue))
def __cinit__(self):
self._c_queue = cqueue.queue_new()
if self._c_queue is cython.NULL:
raise MemoryError()
|