Commit f8f0c3fa authored by Diederik van Arkel's avatar Diederik van Arkel
Browse files

clear type propagation info from var heap

parent 6ecd8b4a
......@@ -2178,6 +2178,7 @@ typeProgram comps main_dcl_module_n fun_defs specials list_inferred_types icl_de
ali_tail_strict_list_first_instance_indices=tail_strict_list_first_instance_indices,
ali_instances_range={ ir_from = fun_env_size, ir_to = special_instances.si_next_array_member_index }
}
# ts_var_heap = clear_var_heap ti_functions ts_var_heap
= (not type_error, fun_defs, array_and_list_instances, type_code_instances, ti_common_defs, ti_functions,
ts_td_infos, {hp_var_heap = ts_var_heap, hp_expression_heap = ts_expr_heap, hp_type_heaps = ts_type_heaps, hp_generic_heap=ts_generic_heap },
predef_symbols, ts_error.ea_file, out)
......@@ -2745,6 +2746,24 @@ where
CheckedType _
-> ts
clear_var_heap fun_types var_heap
= mapArraySt clear_module fun_types var_heap
where
clear_module module_types var_heap
= mapArraySt clear_function module_types var_heap
clear_function {ft_type_ptr} var_heap
| isNilPtr ft_type_ptr
= var_heap
= var_heap <:= (ft_type_ptr, VI_Empty)
mapArraySt f a s :== map_a_st 0 a s
where
map_a_st i a st
| i==size a
= st
# (ai, a) = a![i]
= map_a_st (i+1) a (f ai st)
is_rare_name {id_name}
= id_name.[0]=='_'
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment