def SetDeclarations(self, declarations): Exporter.SetDeclarations(self, declarations) decl = self.GetDeclaration(self.info.name) if isinstance(decl, Typedef): self.class_ = self.GetDeclaration(decl.type.name) if not self.info.rename: self.info.rename = decl.name else: self.class_ = decl self.public_members = \ [x for x in self.class_.members if x.visibility == Scope.public]
def SetDeclarations(self, declarations): Exporter.SetDeclarations(self, declarations) if self.declarations: decl = self.GetDeclaration(self.info.name) if isinstance(decl, Typedef): self.class_ = self.GetDeclaration(decl.type.name) if not self.info.rename: self.info.rename = decl.name else: self.class_ = decl self.class_ = copy.deepcopy(self.class_) else: self.class_ = None
def SetDeclarations(self, declarations): def IsInternalName(name): '''Returns true if the given name looks like a internal compiler structure''' return name.startswith('__') Exporter.SetDeclarations(self, declarations) header = os.path.normpath(self.parser_header) for decl in declarations: # check if this declaration is in the header location = os.path.normpath(decl.location[0]) if location != header or IsInternalName(decl.name): continue # ok, check the type of the declaration and export it accordingly self.HandleDeclaration(decl)
def SetDeclarations(self, declarations): Exporter.SetDeclarations(self, declarations) self.enum = self.GetDeclaration(self.info.name)
def SetDeclarations(self, declarations): Exporter.SetDeclarations(self, declarations) if self.declarations: self.enum = self.GetDeclaration(self.info.name) else: self.enum = None