Commit 727e57d9 authored by scoder's avatar scoder

Merge pull request #327 from nbarbey/master

Allow to use Plex as an external parsing library with unicode support
parents f9357d3c 21ce6b27
...@@ -178,7 +178,7 @@ class FastMachine(object): ...@@ -178,7 +178,7 @@ class FastMachine(object):
state['else'] = new_state state['else'] = new_state
elif code1 != maxint: elif code1 != maxint:
while code0 < code1: while code0 < code1:
state[chr(code0)] = new_state state[unichr(code0)] = new_state
code0 = code0 + 1 code0 = code0 + 1
else: else:
state[event] = new_state state[event] = new_state
......
...@@ -31,7 +31,7 @@ cdef class Scanner: ...@@ -31,7 +31,7 @@ cdef class Scanner:
@cython.locals(input_state=long) @cython.locals(input_state=long)
cdef next_char(self) cdef next_char(self)
@cython.locals(action=Action) @cython.locals(action=Action)
cdef tuple read(self) cpdef tuple read(self)
cdef tuple scan_a_token(self) cdef tuple scan_a_token(self)
cdef tuple position(self) cdef tuple position(self)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment