Commit 345009e0 authored by Stefan Behnel's avatar Stefan Behnel

reverted last change - generates problematic C code

parent 24e2ac27
...@@ -1559,8 +1559,7 @@ class CClassScope(ClassScope): ...@@ -1559,8 +1559,7 @@ class CClassScope(ClassScope):
error(pos, "'%s' already defined" % name) error(pos, "'%s' already defined" % name)
#print "CClassScope.declare_cfunction: checking signature" ### #print "CClassScope.declare_cfunction: checking signature" ###
if type.same_c_signature_as(entry.type, as_cmethod = 1) and type.nogil == entry.type.nogil: if type.same_c_signature_as(entry.type, as_cmethod = 1) and type.nogil == entry.type.nogil:
# may still need to adjust the type of 'self' => simply override the type pass
entry.type = type
elif type.compatible_signature_with(entry.type, as_cmethod = 1) and type.nogil == entry.type.nogil: elif type.compatible_signature_with(entry.type, as_cmethod = 1) and type.nogil == entry.type.nogil:
entry = self.add_cfunction(name, type, pos, cname or name, visibility='ignore', modifiers=modifiers) entry = self.add_cfunction(name, type, pos, cname or name, visibility='ignore', modifiers=modifiers)
defining = 1 defining = 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