diff options
author | Adam Chlipala <adamc@hcoop.net> | 2009-05-16 15:45:12 -0400 |
---|---|---|
committer | Adam Chlipala <adamc@hcoop.net> | 2009-05-16 15:45:12 -0400 |
commit | 3d77d43fda3acfa1d5f1e12c836718d79fdf84db (patch) | |
tree | c5073d9b7f368aa38bb4d146c0a6b21900ef1f79 /src/marshalcheck.sml | |
parent | d889f05df404ac119cf864854e6fdfb4b5636472 (diff) |
Mutual datatypes through Effectize
Diffstat (limited to 'src/marshalcheck.sml')
-rw-r--r-- | src/marshalcheck.sml | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/marshalcheck.sml b/src/marshalcheck.sml index 3dbf93fc..10129aef 100644 --- a/src/marshalcheck.sml +++ b/src/marshalcheck.sml @@ -75,12 +75,13 @@ fun check file = ignore (foldl (fn ((d, _), (cmap, emap)) => case d of DCon (_, n, _, c) => (IM.insert (cmap, n, sins cmap c), emap) - | DDatatype (_, n, _, xncs) => - (IM.insert (cmap, n, foldl (fn ((_, _, co), s) => - case co of - NONE => s - | SOME c => PS.union (s, sins cmap c)) - PS.empty xncs), + | DDatatype dts => + (foldl (fn ((_, n, _, xncs), cmap) => + IM.insert (cmap, n, foldl (fn ((_, _, co), s) => + case co of + NONE => s + | SOME c => PS.union (s, sins cmap c)) + PS.empty xncs)) cmap dts, emap) | DVal (_, n, t, _, tag) => (cmap, IM.insert (emap, n, (t, tag))) |