Commit 0621c71a authored by Stefan Behnel's avatar Stefan Behnel

Minor safety fix in parser: only check s.systring when s.sy == 'IDENT'.

parent 60700546
......@@ -2480,7 +2480,7 @@ def p_c_simple_base_type(s, self_flag, nonempty, templates = None):
# Handle const/volatile
is_const = is_volatile = 0
while True:
while s.sy == 'IDENT':
if s.systring == 'const':
if is_const: error(pos, "Duplicate 'const'")
is_const = 1
......
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