Commits

Armin Rigo committed 613cd8c

Fix the front-end to work (but still show $ signs)

  • Participants
  • Parent commits 3306e1a

Comments (0)

Files changed (2)

cffi/backend_ctypes.py

         class CTypesStructOrUnion(CTypesBaseStructOrUnion):
             __slots__ = ['_blob']
             _ctype = struct_or_union
-            _reftypename = '%s %s &' % (kind, name)
+            _reftypename = '%s &' % (name,)
             _kind = kind
         #
         CTypesStructOrUnion._fix_class()
     def build_backend_type(self, ffi, finishlist):
         self.check_not_partial()
         finishlist.append(self)
-        return global_cache(self, ffi, 'new_struct_type', self.name, key=self)
+        return global_cache(self, ffi, 'new_struct_type',
+                            'struct ' + self.name, key=self)
 
 
 class UnionType(StructOrUnion):
 
     def build_backend_type(self, ffi, finishlist):
         finishlist.append(self)
-        return global_cache(self, ffi, 'new_union_type', self.name, key=self)
+        return global_cache(self, ffi, 'new_union_type',
+                            'union ' + self.name, key=self)
 
 
 class EnumType(StructOrUnionOrEnum):