mv lexer.py -> lexrules.py, remove get_lexer() and ply import
This commit is contained in:
parent
bcb1e6a6ff
commit
71f4b01c23
@ -1,6 +1,4 @@
|
|||||||
|
|
||||||
import ply.lex as lex
|
|
||||||
|
|
||||||
reserved = {
|
reserved = {
|
||||||
'C': 'C',
|
'C': 'C',
|
||||||
}
|
}
|
||||||
@ -33,6 +31,3 @@ def t_newline(t):
|
|||||||
def t_error(t):
|
def t_error(t):
|
||||||
print 'Illegal character "%s"' % t.value[0]
|
print 'Illegal character "%s"' % t.value[0]
|
||||||
t.lexer.skip(1)
|
t.lexer.skip(1)
|
||||||
|
|
||||||
def get_lexer():
|
|
||||||
return lex.lex()
|
|
Loading…
x
Reference in New Issue
Block a user