minor cythonisation and cleanup in Scanners.pxd
authorStefan Behnel <scoder@users.berlios.de>
Sat, 14 Mar 2009 22:04:35 +0000 (23:04 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Sat, 14 Mar 2009 22:04:35 +0000 (23:04 +0100)
Cython/Plex/Scanners.pxd

index fe09cff065cf18f6ef2415ecfb08fc9eb63ca0f4..c40d8e6dedca8309479b5ff157774b34e66694a2 100644 (file)
@@ -26,15 +26,15 @@ cdef class Scanner:
 
     @cython.locals(input_state=long)
     cpdef next_char(self)
-    cpdef read(self)
+    @cython.locals(queue=list)
+    cpdef tuple read(self)
     cpdef tuple scan_a_token(self)
     cpdef tuple position(self)
 
-    @cython.locals(cur_pos=cython.long, cur_line=cython.long,
-                 cur_line_start=cython.long, input_state=cython.long,
-                 next_pos=cython.long, buf_start_pos=cython.long,
-                 buf_len=cython.long, buf_index=cython.long,
-                 trace=cython.bint, discard=cython.long)
+    @cython.locals(cur_pos=long, cur_line=long, cur_line_start=long,
+                   input_state=long, next_pos=long,
+                   buf_start_pos=long, buf_len=long, buf_index=long,
+                   trace=bint, discard=long)
     cpdef run_machine_inlined(self)
     
     cpdef begin(self, state)