aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/corify.sml
diff options
context:
space:
mode:
authorGravatar Karn Kallio <kkallio@eka>2011-05-06 15:24:45 -0530
committerGravatar Karn Kallio <kkallio@eka>2011-05-06 15:24:45 -0530
commit9da48d9f4d28eea826e0651a0aee761a964682f2 (patch)
treea053657c7e56e6b0c33025cb5412285b65a953fa /src/corify.sml
parentb25211f8bdd3c17b9d56158a8c71712f2ed20f63 (diff)
Corify Basis.unit to empty record; this is needed so that specialize
can see that they are equivalent.
Diffstat (limited to 'src/corify.sml')
-rw-r--r--src/corify.sml6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/corify.sml b/src/corify.sml
index 075047a2..706a4c2d 100644
--- a/src/corify.sml
+++ b/src/corify.sml
@@ -466,7 +466,11 @@ fun corifyCon st (c, loc) =
in
case St.lookupConByName st x of
St.CNormal n => (L'.CNamed n, loc)
- | St.CFfi m => (L'.CFfi (m, x), loc)
+ | St.CFfi m =>
+ if (m, x) = ("Basis", "unit") then
+ (L'.TRecord (L'.CRecord ((L'.KType, loc), []), loc), loc)
+ else
+ (L'.CFfi (m, x), loc)
end
| L.CApp (c1, c2) => (L'.CApp (corifyCon st c1, corifyCon st c2), loc)