Commit 59ec7599 authored by Stefan Behnel's avatar Stefan Behnel

do not leak C++ namespace into outer parser scope when parsing 'cdef extern' blocks

parent b106213b
......@@ -2186,10 +2186,10 @@ def p_cdef_extern_block(s, pos, ctx):
s.next()
else:
_, include_file = p_string_literal(s)
ctx = ctx(cdef_flag = 1, visibility = 'extern')
if s.systring == "namespace":
s.next()
ctx.namespace = p_string_literal(s)[1]
ctx = ctx(cdef_flag = 1, visibility = 'extern')
if p_nogil(s):
ctx.nogil = 1
body = p_suite(s, ctx)
......
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