Commit 283fbb05 authored by Lisandro Dalcin's avatar Lisandro Dalcin

Use PyMapping_DelItem() with interned cname

parent ae6743bc
...@@ -1679,10 +1679,11 @@ class NameNode(AtomicExprNode): ...@@ -1679,10 +1679,11 @@ class NameNode(AtomicExprNode):
return # There was an error earlier return # There was an error earlier
elif self.entry.is_pyclass_attr: elif self.entry.is_pyclass_attr:
namespace = self.entry.scope.namespace_cname namespace = self.entry.scope.namespace_cname
interned_cname = code.intern_identifier(self.entry.name)
code.put_error_if_neg(self.pos, code.put_error_if_neg(self.pos,
'PyMapping_DelItemString(%s, "%s")' % ( 'PyMapping_DelItem(%s, %s)' % (
namespace, namespace,
self.entry.name)) interned_cname))
elif self.entry.is_pyglobal: elif self.entry.is_pyglobal:
code.put_error_if_neg(self.pos, code.put_error_if_neg(self.pos,
'__Pyx_DelAttrString(%s, "%s")' % ( '__Pyx_DelAttrString(%s, "%s")' % (
......
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