Pass re.VERBOSE explicitly

ply doesn't add re.VERBOSE flag by default anymore, so we need to pass it
explicitly.

Change-Id: I42b0830b7f30806ddbe42f57f54cc050a262e2e2
This commit is contained in:
Georgy Kibardin 2017-02-03 08:10:29 +03:00
parent 57cc3de6fc
commit e7a7f60631
1 changed files with 2 additions and 1 deletions

View File

@ -237,7 +237,8 @@ class YaqlFactory(object):
names = self._name_generator()
operators = self._build_operator_table(names)
lexer_rules = self._create_lexer(operators)
ply_lexer = lex.lex(object=lexer_rules, reflags=re.UNICODE)
ply_lexer = lex.lex(object=lexer_rules,
reflags=re.UNICODE | re.VERBOSE)
ply_parser = yacc.yacc(
module=self._create_parser(lexer_rules, operators),
debug=False if not options else options.get('yaql.debug', False),