aboutsummaryrefslogtreecommitdiff
path: root/sucl/absmodule.icl
blob: 4c0f1bea4708d9213170f956f271981eafdbdd1f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
implementation module absmodule

// $Id$

import rule

/*

------------------------------------------------------------------------
Exports.

>   %export
>       module
>       addtalias
>       addtsymdef
>       addalias
>       addsymdef
>       newmodule

------------------------------------------------------------------------
Includes.

>   %include "basic.lit"
>   %include "graph.lit" -extgraph
>   %include "rule.lit"

------------------------------------------------------------------------
Module implementation.

*/

:: Module sym pvar tsym tvar
   = { arities             :: [(sym,Int)]               // Arity of each symbol
     , typeconstructors    :: [(tsym,[sym])]            // All constructor symbols of each declared algebraic type
     , exportedsymbols     :: [sym]                     // Exported function/constructor symbols
     , typerules           :: [(sym,Rule tsym tvar)]    // Principal types of symbols
     , stricts             :: [(sym,[Bool])]            // Strict arguments of functions
     , rules               :: [(sym,[Rule sym pvar])]   // Rewrite rules of each symbol, absent if imported
     }