Commit 6af8a575 authored by John van Groningen's avatar John van Groningen
Browse files

remove code that is no longer used in unfold, because unfold is no longer

used by module trans (now uses copy)
parent a18fce99
...@@ -203,9 +203,8 @@ where ...@@ -203,9 +203,8 @@ where
= (Case {cees & case_info_ptr=new_case_info_ptr},symbol_heap) = (Case {cees & case_info_ptr=new_case_info_ptr},symbol_heap)
replace_variables_in_expression expr var_heap symbol_heap replace_variables_in_expression expr var_heap symbol_heap
# us = { us_var_heap = var_heap, us_symbol_heap = symbol_heap, us_opt_type_heaps = No,us_cleanup_info = [], us_local_macro_functions = No } # us = { us_var_heap = var_heap, us_symbol_heap = symbol_heap, us_local_macro_functions = No }
ui = {ui_handle_aci_free_vars = RemoveThem} (expr, us) = unfold expr us
(expr, us) = unfold expr ui us
= (expr, us.us_var_heap, us.us_symbol_heap) = (expr, us.us_var_heap, us.us_symbol_heap)
new_variable fv=:{fv_ident, fv_info_ptr} var_heap new_variable fv=:{fv_ident, fv_info_ptr} var_heap
...@@ -378,9 +377,8 @@ where ...@@ -378,9 +377,8 @@ where
replace_variables vars expr ap_vars var_heap symbol_heap replace_variables vars expr ap_vars var_heap symbol_heap
# var_heap = build_aliases vars ap_vars var_heap # var_heap = build_aliases vars ap_vars var_heap
# us = { us_var_heap = var_heap, us_symbol_heap = symbol_heap, us_opt_type_heaps = No,us_cleanup_info=[], us_local_macro_functions = No } # us = { us_var_heap = var_heap, us_symbol_heap = symbol_heap, us_local_macro_functions = No }
ui = {ui_handle_aci_free_vars = RemoveThem } (expr, us) = unfold expr us
(expr, us) = unfold expr ui us
= (expr, us.us_var_heap, us.us_symbol_heap) = (expr, us.us_var_heap, us.us_symbol_heap)
where where
build_aliases [var1 : vars1] [ {fv_ident,fv_info_ptr} : vars2 ] var_heap build_aliases [var1 : vars1] [ {fv_ident,fv_info_ptr} : vars2 ] var_heap
......
...@@ -31,16 +31,8 @@ determineVariablesAndRefCounts :: ![FreeVar] !Expression !*CollectState -> (!Exp ...@@ -31,16 +31,8 @@ determineVariablesAndRefCounts :: ![FreeVar] !Expression !*CollectState -> (!Exp
:: UnfoldState = :: UnfoldState =
{ us_var_heap :: !.VarHeap { us_var_heap :: !.VarHeap
, us_symbol_heap :: !.ExpressionHeap , us_symbol_heap :: !.ExpressionHeap
, us_opt_type_heaps :: !.Optional .TypeHeaps, , us_local_macro_functions :: !Optional CopiedLocalFunctions
us_cleanup_info :: ![ExprInfoPtr],
us_local_macro_functions :: !Optional CopiedLocalFunctions
} }
:: UnfoldInfo = class unfold a :: !a !*UnfoldState -> (!a, !*UnfoldState)
{ ui_handle_aci_free_vars :: !AciFreeVarHandleMode
}
:: AciFreeVarHandleMode = LeaveThem | RemoveThem | SubstituteThem
class unfold a :: !a !UnfoldInfo !*UnfoldState -> (!a, !*UnfoldState)
instance unfold Expression, CasePatterns instance unfold Expression, CasePatterns
This diff is collapsed.
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