Exemple #1
0
 def p_return_type_5(self, p):
     r'''return_type :   ID'''
     p[0] = NoneTerminal(p)
     p[0].rtype = "\n\nNON SUPPORTED VARIABLE TYPE!\n\n"
Exemple #2
0
 def p_return_type_4(self, p):
     r'''return_type :   STRING_TYPE'''
     p[0] = NoneTerminal(p)
     p[0].rtype = "char*"
Exemple #3
0
 def p_return_type_2(self, p):
     r'''return_type :   REAL_TYPE'''
     p[0] = NoneTerminal(p)
     p[0].rtype = "double"
Exemple #4
0
 def p_return_type_3(self, p):
     r'''return_type :   BOOL_TYPE'''
     p[0] = NoneTerminal(p)
     p[0].rtype = "bool"
Exemple #5
0
 def p_var_type_1(self, p):
     r'''var_type :   return_type'''
     p[0] = NoneTerminal(p)
     p[0].rtype = p[1].rtype