Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
clean-compiler-and-rts
compiler
Commits
a0d0f775
Commit
a0d0f775
authored
Mar 26, 2002
by
John van Groningen
Browse files
set the explicit flag for cases generated for && and || to True
parent
219a8e2f
Changes
1
Hide whitespace changes
Inline
Side-by-side
frontend/transform.icl
View file @
a0d0f775
...
...
@@ -1272,8 +1272,6 @@ where
has_no_curried_macro_Selections
[]
=
True
import
StdDebug
partitionateAndLiftFunctions
::
![
IndexRange
]
!
Index
!
PredefSymbolsForTransform
!*{#
FunDef
}
!*{#*{#
FunDef
}}
!*{#
DclModule
}
!*
VarHeap
!*
ExpressionHeap
!*
SymbolTable
!*
ErrorAdmin
->
(!*{!
Group
},
!*{#
FunDef
},!*{#*{#
FunDef
}},!.{#
DclModule
},!*
VarHeap
,!*
ExpressionHeap
,!*
SymbolTable
,!*
ErrorAdmin
)
partitionateAndLiftFunctions
ranges
main_dcl_module_n
predef_symbols_for_transform
fun_defs
macro_defs
modules
var_heap
symbol_heap
symbol_table
error
...
...
@@ -1342,21 +1340,14 @@ where
))
->
(
max_fun_nr
,
(
modules
,
pi
))
GeneratedBody
/*
/*
// allocate a group that contains this and only this function
| fun_def.fun_info.fi_group_index == NoIndex
# pi =
{ pi
& pi_fun_defs.[fun_index] =
{ fun_def
& fun_info.fi_group_index = pi.pi_next_group
}
, pi_groups = [[FunctionOrIclMacroIndex fun_index] : pi.pi_groups]
, pi_next_group = inc pi.pi_next_group
}
# pi = { pi & pi_fun_defs.[fun_index] = { fun_def & fun_info.fi_group_index = pi.pi_next_group },
pi_groups = [[FunctionOrIclMacroIndex fun_index] : pi.pi_groups] , pi_next_group = inc pi.pi_next_group }
-> (max_fun_nr, (modules, pi))
-> abort ("generated function already has a group index: " +++ toString fun_def.fun_symb +++ " " +++ toString fun_index +++ "\n")
*/
*/
// do not allocate a group, it will be allocated during generic phase
->
(
max_fun_nr
,
(
modules
,
pi
))
partitionate_macro
mod_index
max_fun_nr
macro_module_index
macro_index
(
modules
,
pi
)
...
...
@@ -1854,7 +1845,7 @@ where
#
(
new_info_ptr
,
symbol_heap
)
=
newPtr
EI_Empty
cos
.
cos_symbol_heap
#
kase
=
Case
{
case_expr
=
e1
,
case_guards
=
BasicPatterns
BT_Bool
[{
bp_value
=
BVB
True
,
bp_expr
=
e2
,
bp_position
=
NoPos
}],
case_default
=
Yes
e3
,
case_ident
=
No
,
case_info_ptr
=
new_info_ptr
,
case_default_pos
=
NoPos
,
case_explicit
=
Fals
e
}
case_explicit
=
Tru
e
}
=
(
kase
,{
cos
&
cos_symbol_heap
=
symbol_heap
});
two_args
[_,_]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment