comparison src/explify.sml @ 208:63a2f2322c1f

-timing option for command-line compiler
author Adam Chlipala <adamc@hcoop.net>
date Sat, 16 Aug 2008 10:54:46 -0400
parents dd82457fda82
children e86411f647c6
comparison
equal deleted inserted replaced
207:cc68da3801bc 208:63a2f2322c1f
37 | L.KArrow (k1, k2) => (L'.KArrow (explifyKind k1, explifyKind k2), loc) 37 | L.KArrow (k1, k2) => (L'.KArrow (explifyKind k1, explifyKind k2), loc)
38 | L.KName => (L'.KName, loc) 38 | L.KName => (L'.KName, loc)
39 | L.KRecord k => (L'.KRecord (explifyKind k), loc) 39 | L.KRecord k => (L'.KRecord (explifyKind k), loc)
40 40
41 | L.KUnit => (L'.KUnit, loc) 41 | L.KUnit => (L'.KUnit, loc)
42 | L.KTuple _ => raise Fail "Explify KTuple"
42 43
43 | L.KError => raise Fail ("explifyKind: KError at " ^ EM.spanToString loc) 44 | L.KError => raise Fail ("explifyKind: KError at " ^ EM.spanToString loc)
44 | L.KUnif (_, _, ref (SOME k)) => explifyKind k 45 | L.KUnif (_, _, ref (SOME k)) => explifyKind k
45 | L.KUnif _ => raise Fail ("explifyKind: KUnif at " ^ EM.spanToString loc) 46 | L.KUnif _ => raise Fail ("explifyKind: KUnif at " ^ EM.spanToString loc)
46 47
64 | L.CRecord (k, xcs) => (L'.CRecord (explifyKind k, map (fn (c1, c2) => (explifyCon c1, explifyCon c2)) xcs), loc) 65 | L.CRecord (k, xcs) => (L'.CRecord (explifyKind k, map (fn (c1, c2) => (explifyCon c1, explifyCon c2)) xcs), loc)
65 | L.CConcat (c1, c2) => (L'.CConcat (explifyCon c1, explifyCon c2), loc) 66 | L.CConcat (c1, c2) => (L'.CConcat (explifyCon c1, explifyCon c2), loc)
66 | L.CFold (dom, ran) => (L'.CFold (explifyKind dom, explifyKind ran), loc) 67 | L.CFold (dom, ran) => (L'.CFold (explifyKind dom, explifyKind ran), loc)
67 68
68 | L.CUnit => (L'.CUnit, loc) 69 | L.CUnit => (L'.CUnit, loc)
70
71 | L.CTuple _ => raise Fail "Explify CTuple"
72 | L.CProj _ => raise Fail "Explify CProj"
69 73
70 | L.CError => raise Fail ("explifyCon: CError at " ^ EM.spanToString loc) 74 | L.CError => raise Fail ("explifyCon: CError at " ^ EM.spanToString loc)
71 | L.CUnif (_, _, _, ref (SOME c)) => explifyCon c 75 | L.CUnif (_, _, _, ref (SOME c)) => explifyCon c
72 | L.CUnif _ => raise Fail ("explifyCon: CUnif at " ^ EM.spanToString loc) 76 | L.CUnif _ => raise Fail ("explifyCon: CUnif at " ^ EM.spanToString loc)
73 77