aboutsummaryrefslogtreecommitdiff
path: root/frontend/transform.icl
diff options
context:
space:
mode:
authoralimarin2002-03-25 15:04:33 +0000
committeralimarin2002-03-25 15:04:33 +0000
commit5ed289050bba7924972700181478cb22e9d69c70 (patch)
tree43d0c8ebe33e14ad0d4f637ddae3de94acd7bf07 /frontend/transform.icl
parentfix version number (diff)
new implementation of generics
git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@1062 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'frontend/transform.icl')
-rw-r--r--frontend/transform.icl19
1 files changed, 18 insertions, 1 deletions
diff --git a/frontend/transform.icl b/frontend/transform.icl
index d5d3e73..caa94e2 100644
--- a/frontend/transform.icl
+++ b/frontend/transform.icl
@@ -1341,7 +1341,24 @@ where
// {pi & pi_next_group = pi.pi_next_group}
))
-> (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
+ }
+ -> (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)
# (fun_def, pi) = pi!pi_macro_defs.[macro_module_index,macro_index]
= case fun_def.fun_body of