/breezy/unstable

To get this branch, use:
bzr branch https://code.breezy-vcs.org/breezy/unstable

« back to all changes in this revision

Viewing changes to breezy/_simple_set_pyx.pxd

Merge trunk, address review comments.

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
     eg. SimpleSet.add(key) => saved_key and SimpleSet[key] => saved_key
24
24
"""
25
25
 
26
 
cdef extern from "Python.h":
27
 
    ctypedef struct PyObject:
28
 
        pass
 
26
from cpython.object cimport PyObject
29
27
 
30
28
 
31
29
cdef public api class SimpleSet [object SimpleSetObject, type SimpleSet_Type]:
74
72
                            # so we manage it manually
75
73
 
76
74
    cdef PyObject *_get(self, object key) except? NULL
77
 
    cdef object _add(self, key)
78
 
    cdef int _discard(self, key) except -1
 
75
    cpdef object add(self, key)
 
76
    cpdef bint discard(self, key) except -1
79
77
    cdef int _insert_clean(self, PyObject *key) except -1
80
78
    cdef Py_ssize_t _resize(self, Py_ssize_t min_unused) except -1
81
79