assoc.pyx, sym.pyx: Mark arguments as `not None'.
authorMark Wooding <mdw@distorted.org.uk>
Thu, 27 Jul 2017 09:49:10 +0000 (10:49 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Wed, 16 Aug 2017 03:31:32 +0000 (04:31 +0100)
They should have been marked before, but I was careless.  Apparently
this will be the default in future, which seems like a good thing.

assoc.pyx
sym.pyx

index 38b8446..7685dd6 100644 (file)
--- a/assoc.pyx
+++ b/assoc.pyx
@@ -73,7 +73,7 @@ cdef class AssocTable (Mapping):
 cdef class _AssocIter (_MapIterator):
   cdef AssocTable t
   cdef assoc_iter i
-  def __cinit__(me, AssocTable t):
+  def __cinit__(me, AssocTable t not None):
     me.t = t
     assoc_mkiter(&me.i, &me.t._t)
   cdef void *_next(me):
diff --git a/sym.pyx b/sym.pyx
index 48ba3f0..eab6984 100644 (file)
--- a/sym.pyx
+++ b/sym.pyx
@@ -71,7 +71,7 @@ cdef class SymTable (Mapping):
 cdef class _SymIter (_MapIterator):
   cdef SymTable t
   cdef sym_iter i
-  def __cinit__(me, SymTable t):
+  def __cinit__(me, SymTable t not None):
     me.t = t
     sym_mkiter(&me.i, &me.t._t)
   cdef void *_next(me):