Commit 33c9c463 authored by Stefan Behnel's avatar Stefan Behnel

prevent unicode strings from being interned

parent a59f0888
...@@ -442,7 +442,7 @@ class Scope: ...@@ -442,7 +442,7 @@ class Scope:
# Python identifier, it will be interned. # Python identifier, it will be interned.
if not entry.pystring_cname: if not entry.pystring_cname:
value = entry.init value = entry.init
if identifier_pattern.match(value): if identifier_pattern.match(value) and isinstance(value, str):
entry.pystring_cname = self.intern(value) entry.pystring_cname = self.intern(value)
entry.is_interned = 1 entry.is_interned = 1
else: else:
......
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