aboutsummaryrefslogtreecommitdiff
path: root/sucl
diff options
context:
space:
mode:
authorzweije2001-08-10 14:41:22 +0000
committerzweije2001-08-10 14:41:22 +0000
commitf5e4a470cb06d85b0e2b445fe60cbf331f07328b (patch)
tree6b3a9831a85660ced13c70202eb0dea29a76d4b8 /sucl
parentThis commit was generated by cvs2svn to compensate for changes in r612, (diff)
This commit was generated by cvs2svn to compensate for changes in r614,
which included commits to RCS files with non-trunk default branches. git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@615 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'sucl')
-rw-r--r--sucl/newtest.icl28
1 files changed, 28 insertions, 0 deletions
diff --git a/sucl/newtest.icl b/sucl/newtest.icl
index cdec40d..9b65610 100644
--- a/sucl/newtest.icl
+++ b/sucl/newtest.icl
@@ -2,6 +2,12 @@ implementation module newtest
// $Id$
+import cli
+import coreclean
+import canon
+import basic
+import StdEnv
+
/*
newtest.lit - Testing the new trace implementation
@@ -242,7 +248,29 @@ these tuples.
> foldarea' = foldarea (labelarea'.canonise')
> labelarea' = labelarea (map getinit results) (newsymbols main)
> canonise' = canonise (typerule cli) heap
+*/
+
+fullsymred ::
+ [SuclSymbol] // Fresh function symbols
+ Cli // Module to optimise
+ -> [Symredresult symbol node typesymbol typenode]
+
+fullsymred freshsymbols cli
+ = results
+ where results = depthfirst generate process (initareas cli)
+ generate result = map canonise` (getareas result)
+ process area = symredarea foldarea` cli area
+ foldarea` = foldarea (labelarea` o canonise`)
+ labelarea` = labelarea (map getinit results) freshsymbols
+ canonise` = canonise (typerule cli) suclheap
+
+initareas = undef
+getareas = undef
+symredarea = undef
+getinit = undef
+
+/*
`Initareas cli' is the list of initial rooted graphs that must be
symbolically reduced. An initial rooted graph is formed by applying an
exported symbol to its full complement of open arguments according to