From db9e59813541e06caece64592854862bab9c0138 Mon Sep 17 00:00:00 2001 From: ronny Date: Tue, 5 Oct 1999 13:09:14 +0000 Subject: Initial import git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@2 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d --- frontend/transform.dcl | 75 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 frontend/transform.dcl (limited to 'frontend/transform.dcl') diff --git a/frontend/transform.dcl b/frontend/transform.dcl new file mode 100644 index 0000000..79e47e8 --- /dev/null +++ b/frontend/transform.dcl @@ -0,0 +1,75 @@ +definition module transform + +import syntax, checksupport + +:: Group = + { group_members :: ![Int] + } + +partitionateAndLiftFunctions :: ![IndexRange] !Index !*{# FunDef} !u:{# DclModule} !*VarHeap !*ExpressionHeap !*SymbolTable !*ErrorAdmin + -> (!*{! Group}, !*{# FunDef}, !u:{# DclModule}, !*VarHeap, !*ExpressionHeap, !*SymbolTable, !*ErrorAdmin ) + +partitionateMacros :: !IndexRange !Index !*{# FunDef} !u:{# DclModule} !*VarHeap !*ExpressionHeap !*SymbolTable !*ErrorAdmin + -> (!*{# FunDef}, !u:{# DclModule}, !*VarHeap, !*ExpressionHeap, !*SymbolTable, !*ErrorAdmin ) + +:: UnfoldState = + { us_var_heap :: !.VarHeap + , us_symbol_heap :: !.ExpressionHeap + } + +class unfold a :: !a !*UnfoldState -> (!a, !*UnfoldState) + +instance unfold Expression//, PatternExpression + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.2.3