Lines Matching refs:self
31 def __init__(self, slicc, type_ast, value):
32 super(EnumExprAST, self).__init__(slicc)
37 self.type_ast = type_ast
38 self.value = value
40 def __repr__(self):
41 return "[EnumExpr: %s:%s]" % (self.type_ast, self.value)
43 def generate(self, code):
45 code('${{self.type_ast.type.c_ident}}_${{self.value}}')
49 if self.value not in self.type_ast.type.enums:
50 self.error("Type '%s' does not have enumeration '%s'",
51 self.type_ast, self.value)
53 return self.type_ast.type