Mercurial > urweb
comparison src/source.sml @ 30:e6ccf961d8a3
Parsing and printing basic module system
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 12 Jun 2008 14:04:22 -0400 |
parents | 9a578171de9e |
children | 44b5405e74c7 |
comparison
equal
deleted
inserted
replaced
29:537db4ee89f4 | 30:e6ccf961d8a3 |
---|---|
75 | ERecord of (con * exp) list | 75 | ERecord of (con * exp) list |
76 | EField of exp * con | 76 | EField of exp * con |
77 | 77 |
78 withtype exp = exp' located | 78 withtype exp = exp' located |
79 | 79 |
80 datatype sgn_item' = | |
81 SgiConAbs of string * kind | |
82 | SgiCon of string * kind option * con | |
83 | SgiVal of string * con | |
84 | SgiStr of string * sgn | |
85 | |
86 and sgn' = | |
87 SgnConst of sgn_item list | |
88 | SgnVar of string | |
89 | |
90 withtype sgn_item = sgn_item' located | |
91 and sgn = sgn' located | |
92 | |
80 datatype decl' = | 93 datatype decl' = |
81 DCon of string * kind option * con | 94 DCon of string * kind option * con |
82 | DVal of string * con option * exp | 95 | DVal of string * con option * exp |
96 | DSgn of string * sgn | |
97 | DStr of string * sgn option * str | |
98 | |
99 and str' = | |
100 StrConst of decl list | |
101 | StrVar of string | |
83 | 102 |
84 withtype decl = decl' located | 103 withtype decl = decl' located |
104 and str = str' located | |
85 | 105 |
86 type file = decl list | 106 type file = decl list |
87 | 107 |
88 end | 108 end |