Use explicit visibilities in typedef declaration in SingleAssignmentNode.analyse_decl...
authorW. Trevor King <wking@drexel.edu>
Thu, 3 Mar 2011 15:13:30 +0000 (10:13 -0500)
committerW. Trevor King <wking@drexel.edu>
Thu, 3 Mar 2011 15:13:30 +0000 (10:13 -0500)
Cython/Compiler/Nodes.py

index 9c92b8c407bfb23b043e73314c66c701e202ccf6..dbe743b5908072d7894be6d93e500c0dec6ff4de 100644 (file)
@@ -3473,7 +3473,11 @@ class SingleAssignmentNode(AssignmentNode):
                         self.declaration_only = True
                         if not isinstance(lhs, ExprNodes.NameNode):
                             error(lhs.pos, "Invalid declaration.")
-                        env.declare_typedef(lhs.name, type, self.pos, visibility='private')
+                        binding = Binding(
+                            name = lhs.name, c_visibility='private',
+                            visibility='public')
+                        env.WTK_declare_typedef(
+                            binding, base_type = type, pos = self.pos)
 
                 elif func_name in ['struct', 'union']:
                     self.declaration_only = True