fix compiler crash on mangled ctypedef names
authorStefan Behnel <scoder@users.berlios.de>
Fri, 10 Apr 2009 07:04:21 +0000 (09:04 +0200)
committerStefan Behnel <scoder@users.berlios.de>
Fri, 10 Apr 2009 07:04:21 +0000 (09:04 +0200)
Cython/Compiler/Nodes.py

index 8a5044b141ae5a8dbfa7ad45dfa616995027e57b..e67f6af2f7e314ed4eba3d6075cefad82f221d91 100644 (file)
@@ -851,7 +851,8 @@ class CStructOrUnionDefNode(StatNode):
                         cname = self.cname, visibility='ignore')
                     struct_entry.type.typedef_flag = False
                     # FIXME: this might be considered a hack ;-)
-                    struct_entry.cname = struct_entry.type.cname = '_' + self.cname
+                    struct_entry.cname = struct_entry.type.cname = \
+                                         '_' + self.entry.type.typedef_cname
     
     def analyse_expressions(self, env):
         pass