Permalink
Browse files

C++ specialization fix

  • Loading branch information...
1 parent ae0b93d commit a7707ebe41605535d890f36f35b4e6fadac02c47 @robertwb robertwb committed Nov 9, 2012
Showing with 8 additions and 6 deletions.
  1. +8 −6 Cython/Compiler/Symtab.py
View
@@ -2117,18 +2117,20 @@ def specialize(self, values):
entry.pos,
entry.cname,
template=1)
- else:
-# scope.declare_var(entry.name,
-# entry.type.specialize(values),
-# entry.pos,
-# entry.cname,
-# entry.visibility)
+ elif entry.type.is_cfunction:
for e in entry.all_alternatives():
scope.declare_cfunction(e.name,
e.type.specialize(values),
e.pos,
e.cname,
utility_code = e.utility_code)
+ else:
+ scope.declare_var(entry.name,
+ entry.type.specialize(values),
+ entry.pos,
+ entry.cname,
+ entry.visibility)
+
return scope

0 comments on commit a7707eb

Please sign in to comment.