Commit 7abc36ca authored by Stefan Behnel's avatar Stefan Behnel

fix parser crash

--HG--
extra : rebase_source : ac66b38753ea5b4ea9d47ff475ebbf33b19b7c49
parent 150c28d8
......@@ -2462,7 +2462,7 @@ def p_c_arg_decl(s, ctx, in_pyfunc, cmethod_flag = 0, nonempty = 0,
annotation = p_test(s)
if s.sy == '=':
s.next()
if 'pxd' in s.level:
if 'pxd' in ctx.level:
if s.sy not in ['*', '?']:
error(pos, "default values cannot be specified in pxd files, use ? or *")
default = ExprNodes.BoolNode(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