203 /* B 1.4 - Variables */ |
203 /* B 1.4 - Variables */ |
204 /*********************/ |
204 /*********************/ |
205 void *visit(symbolic_variable_c *symbol) { |
205 void *visit(symbolic_variable_c *symbol) { |
206 unsigned int vartype; |
206 unsigned int vartype; |
207 if (wanted_variablegeneration == complextype_base_vg) |
207 if (wanted_variablegeneration == complextype_base_vg) |
208 generate_c_base_c::visit(symbol); |
208 generate_c_base_c::visit(symbol); |
209 else if (wanted_variablegeneration == complextype_suffix_vg) |
209 else if (wanted_variablegeneration == complextype_suffix_vg) |
210 return NULL; |
210 return NULL; |
211 else if (this->is_variable_prefix_null()) { |
211 else if (this->is_variable_prefix_null()) { |
212 vartype = search_varfb_instance_type->get_vartype(symbol); |
212 vartype = search_varfb_instance_type->get_vartype(symbol); |
213 if (wanted_variablegeneration == fparam_output_vg) { |
213 if (wanted_variablegeneration == fparam_output_vg) { |
214 s4o.print("&("); |
214 s4o.print("&("); |
215 generate_c_base_c::visit(symbol); |
215 generate_c_base_c::visit(symbol); |
216 s4o.print(")"); |
216 s4o.print(")"); |
217 } |
217 } |
218 else { |
218 else { |
219 generate_c_base_c::visit(symbol); |
219 generate_c_base_c::visit(symbol); |
220 } |
220 } |
221 } |
221 } |
222 else |
222 else |
223 print_getter(symbol); |
223 print_getter(symbol); |
224 return NULL; |
224 return NULL; |
225 } |
225 } |
226 |
226 |
227 /********************************************/ |
227 /********************************************/ |
228 /* B.1.4.1 Directly Represented Variables */ |
228 /* B.1.4.1 Directly Represented Variables */ |
299 |
299 |
300 current_array_type = search_varfb_instance_type->get_rawtype(symbol->subscripted_variable); |
300 current_array_type = search_varfb_instance_type->get_rawtype(symbol->subscripted_variable); |
301 if (current_array_type == NULL) ERROR; |
301 if (current_array_type == NULL) ERROR; |
302 |
302 |
303 s4o.print(".table"); |
303 s4o.print(".table"); |
|
304 wanted_variablegeneration = expression_vg; |
304 symbol->subscript_list->accept(*this); |
305 symbol->subscript_list->accept(*this); |
|
306 wanted_variablegeneration = complextype_suffix_vg; |
305 |
307 |
306 current_array_type = NULL; |
308 current_array_type = NULL; |
307 break; |
309 break; |
308 default: |
310 default: |
309 if (this->is_variable_prefix_null()) { |
311 if (this->is_variable_prefix_null()) { |