def p_enum_specifier_3(self, p): """ enum_specifier : ENUM ID brace_open enumerator_list brace_close """ p[0] = c_ast.Enum(p[2], p[4], self._token_coord(p, 1))
def p_enum_specifier_2(self, p): """ enum_specifier : ENUM brace_open enumerator_list brace_close """ p[0] = c_ast.Enum(None, p[3], self._token_coord(p, 1))
def p_enum_specifier_1(self, p): """ enum_specifier : ENUM ID """ p[0] = c_ast.Enum(p[2], None, self._token_coord(p, 1))
def p_enum_specifier_3(self, p): """ enum_specifier : ENUM ID LBRACE enumerator_list RBRACE | ENUM TYPEID LBRACE enumerator_list RBRACE """ p[0] = c_ast.Enum(p[2], p[4], self._coord(p.lineno(1)))
def p_enum_specifier_2(self, p): """ enum_specifier : ENUM LBRACE enumerator_list RBRACE """ p[0] = c_ast.Enum(None, p[3], self._coord(p.lineno(1)))
def p_enum_specifier_1(self, p): """ enum_specifier : ENUM ID | ENUM TYPEID """ p[0] = c_ast.Enum(p[2], None, self._coord(p.lineno(1)))