2011-11-24 01:02:48 -08:00
|
|
|
|
2011-11-24 18:37:57 -08:00
|
|
|
# Characters 240-248:
|
2011-11-24 01:02:48 -08:00
|
|
|
let f (Refl : (a T.t, b T.t) eq) = (x :> b)
|
2011-11-24 18:37:57 -08:00
|
|
|
^^^^^^^^
|
|
|
|
Error: Type a is not a subtype of b
|
2011-11-24 01:02:48 -08:00
|
|
|
# Characters 36-67:
|
|
|
|
type (_, +_) eq = Refl : ('a, 'a) eq
|
|
|
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
Error: In this GADT definition, the variance of some parameter
|
|
|
|
cannot be checked
|
|
|
|
# Characters 115-175:
|
|
|
|
.......................................function
|
|
|
|
| BoolLit, false -> false
|
|
|
|
| IntLit , 6 -> false
|
|
|
|
Warning 8: this pattern-matching is not exhaustive.
|
|
|
|
Here is an example of a value that is not matched:
|
|
|
|
(IntLit, 0)
|
2011-12-27 18:22:38 -08:00
|
|
|
type _ t = IntLit : int t | BoolLit : bool t
|
2011-12-27 00:52:45 -08:00
|
|
|
val check : 's t * 's -> bool = <fun>
|
2011-11-24 01:02:48 -08:00
|
|
|
# Characters 91-180:
|
|
|
|
.............................................function
|
|
|
|
| {fst = BoolLit; snd = false} -> false
|
|
|
|
| {fst = IntLit ; snd = 6} -> false
|
|
|
|
Warning 8: this pattern-matching is not exhaustive.
|
|
|
|
Here is an example of a value that is not matched:
|
|
|
|
{fst=IntLit; snd=0}
|
|
|
|
type ('a, 'b) pair = { fst : 'a; snd : 'b; }
|
2011-12-27 00:52:45 -08:00
|
|
|
val check : ('s t, 's) pair -> bool = <fun>
|
2011-11-24 01:02:48 -08:00
|
|
|
#
|