Commit ad585fe6 authored by Martin Wierich's avatar Martin Wierich
Browse files

bugfix: The following let

 #! (a, b) = f

was originally translated into

 #! _x = f
 #! a = _x.0
 #! b = _x.1

which is wrong. Now a an b are in a lazy context
parent 1caf0059
......@@ -1925,7 +1925,8 @@ where
e_state = { e_state & es_var_heap = es_var_heap, es_expr_heap = es_expr_heap }
(strict_array_pattern_binds, lazy_array_pattern_binds, free_vars, e_state, e_info, cs)
= foldSt (buildSelections e_input) array_patterns ([], [], free_vars, e_state, e_info, cs)
all_binds = [if seq_let.ndwl_strict (let_binds,[]) ([],let_binds), (strict_array_pattern_binds, lazy_array_pattern_binds) : binds]
all_binds = [if seq_let.ndwl_strict (s, l) ([],let_binds), (strict_array_pattern_binds, lazy_array_pattern_binds) : binds]
with (l,s) = splitAt ((length let_binds)-1) let_binds
= (all_binds, loc_envs, max_expr_level, free_vars, e_state, e_info, cs)
check_sequential_lets free_vars [] let_vars_list e_input=:{ei_expr_level} e_state e_info cs
= ([], let_vars_list, ei_expr_level, free_vars, e_state, e_info, cs)
......
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