stage4/generate_c/generate_c_base.cc
changeset 98 d0cdf1d00b74
parent 70 e1f0ebd2d9ec
child 118 d4cf7ea933a4
equal deleted inserted replaced
97:55ffcf693d6d 98:d0cdf1d00b74
   251     void *visit(boolean_literal_c *symbol) {return print_literal(symbol->type, symbol->value);}
   251     void *visit(boolean_literal_c *symbol) {return print_literal(symbol->type, symbol->value);}
   252 
   252 
   253     /* helper class for boolean_literal_c */
   253     /* helper class for boolean_literal_c */
   254     void *visit(boolean_true_c *symbol) {s4o.print("TRUE"); return NULL;}
   254     void *visit(boolean_true_c *symbol) {s4o.print("TRUE"); return NULL;}
   255     void *visit(boolean_false_c *symbol) {s4o.print("FALSE"); return NULL;}
   255     void *visit(boolean_false_c *symbol) {s4o.print("FALSE"); return NULL;}
       
   256 
       
   257     void *visit(neg_expression_c *symbol) {
       
   258       s4o.print("-");
       
   259       symbol->exp->accept(*this);
       
   260       return NULL;
       
   261     }
   256 
   262 
   257 /*******************************/
   263 /*******************************/
   258 /* B.1.2.2   Character Strings */
   264 /* B.1.2.2   Character Strings */
   259 /*******************************/
   265 /*******************************/
   260     void *visit(double_byte_character_string_c *symbol) {
   266     void *visit(double_byte_character_string_c *symbol) {
   550 /*************************************/
   556 /*************************************/
   551 #if 0
   557 #if 0
   552 /*  subscripted_variable '[' subscript_list ']' */
   558 /*  subscripted_variable '[' subscript_list ']' */
   553 SYM_REF2(array_variable_c, subscripted_variable, subscript_list)
   559 SYM_REF2(array_variable_c, subscripted_variable, subscript_list)
   554 
   560 
   555 /* subscript_list ',' subscript */
       
   556 SYM_LIST(subscript_list_c)
       
   557 #endif
   561 #endif
   558 
   562 
   559 /*  record_variable '.' field_selector */
   563 /*  record_variable '.' field_selector */
   560 /*  WARNING: input and/or output variables of function blocks
   564 /*  WARNING: input and/or output variables of function blocks
   561  *           may be accessed as fields of a structured variable!
   565  *           may be accessed as fields of a structured variable!