generate_IEC_std.py
changeset 43 4a7e80513edd
parent 40 49c8ebc1ee25
child 58 39cd981ff242
equal deleted inserted replaced
42:4a8400732001 43:4a7e80513edd
   111             for paramname,paramtype,unused in fdecl["inputs"]:
   111             for paramname,paramtype,unused in fdecl["inputs"]:
   112                 code_gen_dic_decl[paramname+"_value"] = '");\n%s_param_value->accept(*this);\ns4o.print("'%(paramname)
   112                 code_gen_dic_decl[paramname+"_value"] = '");\n%s_param_value->accept(*this);\ns4o.print("'%(paramname)
   113                 code_gen_dic_decl[paramname+"_type"] = '");\n%s_type_symbol->accept(*this);\ns4o.print("'%(paramname)
   113                 code_gen_dic_decl[paramname+"_type"] = '");\n%s_type_symbol->accept(*this);\ns4o.print("'%(paramname)
   114             code_gen_dic_decl["return_type"] = '");\nreturn_type_symbol->accept(*this);\ns4o.print("'
   114             code_gen_dic_decl["return_type"] = '");\nreturn_type_symbol->accept(*this);\ns4o.print("'
   115             code_gen_dic_decl["param_count"] = '");\ns4o.print_integer(nb_param);\ns4o.print("'
   115             code_gen_dic_decl["param_count"] = '");\ns4o.print_integer(nb_param);\ns4o.print("'
       
   116             code_gen_dic_decl["common_type"] = '");\nlast_type_symbol->accept(*this);\ns4o.print("'
   116             code_gen_dic_decl["start_bool_filter"] = '");\nif (search_expression_type->is_bool_type(last_type_symbol))\n  s4o.print("('
   117             code_gen_dic_decl["start_bool_filter"] = '");\nif (search_expression_type->is_bool_type(last_type_symbol))\n  s4o.print("('
   117             code_gen_dic_decl["end_bool_filter"] = '");\nif (search_expression_type->is_bool_type(last_type_symbol)) {\n  s4o.print("&1");\n  s4o.print(")");\n}\ns4o.print("'
   118             code_gen_dic_decl["end_bool_filter"] = '");\nif (search_expression_type->is_bool_type(last_type_symbol)) {\n  s4o.print("&1");\n  s4o.print(")");\n}\ns4o.print("'
   118             
   119             
   119             if type(code_gen) == type(tuple()):
   120             if type(code_gen) == type(tuple()):
   120                 res += 's4o.indent_right();\n'
   121                 res += 's4o.indent_right();\n'