stage4/generate_cc/generate_cc_tempvardecl.cc
changeset 32 289256ec66f1
parent 0 fb772792efd1
equal deleted inserted replaced
31:c6959b0f539d 32:289256ec66f1
   112       for(symbol_c *finvocation = NULL; (finvocation = fcall_iterator.next()) != NULL;) {
   112       for(symbol_c *finvocation = NULL; (finvocation = fcall_iterator.next()) != NULL;) {
   113         /* get the name of the next function that gets called */
   113         /* get the name of the next function that gets called */
   114         identifier_c *fcalled_name = fcall_iterator.fname();
   114         identifier_c *fcalled_name = fcall_iterator.fname();
   115         /* get that function's declaration... */
   115         /* get that function's declaration... */
   116         function_declaration_c *fdecl = function_symtable.find_value(fcalled_name);
   116         function_declaration_c *fdecl = function_symtable.find_value(fcalled_name);
   117         if (fdecl == function_symtable.end_value()) ERROR;
   117         if (fdecl == function_symtable.end_value()) {
       
   118           function_type_t function_type = get_function_type(fcalled_name);
       
   119           if (function_type == function_none) ERROR;
       
   120           return;
       
   121         }
   118         /* create iterator to iterate through each of the called function's parameters... */
   122         /* create iterator to iterate through each of the called function's parameters... */
   119         function_param_iterator_c fp_iterator(fdecl);
   123         function_param_iterator_c fp_iterator(fdecl);
   120 
   124 
   121         /* iterate through each of the called function's parameters... */
   125         /* iterate through each of the called function's parameters... */
   122         identifier_c *param_name = NULL;
   126         identifier_c *param_name = NULL;