|
|
@@ -55,17 +55,17 @@ class TestParsers(unittest.TestCase): |
|
|
|
self.assertRaises(ParseError, l.parse, 'a') |
|
|
|
|
|
|
|
def test_utf8(self): |
|
|
|
g = """start: a |
|
|
|
g = u"""start: a |
|
|
|
a: "±a" |
|
|
|
""" |
|
|
|
l = Lark(g) |
|
|
|
l.parse('±a') |
|
|
|
l.parse(u'±a') |
|
|
|
|
|
|
|
l = Lark(g, parser='earley', lexer=None) |
|
|
|
l.parse('±a') |
|
|
|
l.parse(u'±a') |
|
|
|
|
|
|
|
l = Lark(g, parser='earley', lexer='dynamic') |
|
|
|
l.parse('±a') |
|
|
|
l.parse(u'±a') |
|
|
|
|
|
|
|
|
|
|
|
def _make_full_earley_test(LEXER): |
|
|
|