You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original bug ID: 6814 Reporter: ggole Assigned to:@garrigue Status: closed (set by @xavierleroy on 2016-12-07T10:49:12Z) Resolution: not a bug Priority: normal Severity: major Version: 4.02.1 Target version: 4.02.2+dev / +rc1 Fixed in version: 4.02.2+dev / +rc1 Category: typing Monitored by:@hcarty
Bug description
Compiling the following program with -rectypes results in an assertion failure:
As the comment suggests, replacing the underscore (or compiling without -rectypes) avoids the crash.
type (_, _) t =
| Nil : ('t, 't) t
| Cons : ('t -> 'a) * ('r, 't) t -> (('a -> 'r), 't) t
(* replacing the _ here with b results in no crash *)
let test : type a b . a -> (_, a) t -> unit =
fun value -> function
| Nil -> ()
| Cons (getter, rest) -> ignore (getter value)
I also reproduced on 4.03.0.
The text was updated successfully, but these errors were encountered:
Original bug ID: 6814
Reporter: ggole
Assigned to: @garrigue
Status: closed (set by @xavierleroy on 2016-12-07T10:49:12Z)
Resolution: not a bug
Priority: normal
Severity: major
Version: 4.02.1
Target version: 4.02.2+dev / +rc1
Fixed in version: 4.02.2+dev / +rc1
Category: typing
Monitored by: @hcarty
Bug description
Compiling the following program with -rectypes results in an assertion failure:
Fatal error: exception File "typing/typecore.ml", line 1899, characters 65-71: Assertion failed
As the comment suggests, replacing the underscore (or compiling without -rectypes) avoids the crash.
type (_, _) t =
| Nil : ('t, 't) t
| Cons : ('t -> 'a) * ('r, 't) t -> (('a -> 'r), 't) t
(* replacing the _ here with b results in no crash *)
let test : type a b . a -> (_, a) t -> unit =
fun value -> function
| Nil -> ()
| Cons (getter, rest) -> ignore (getter value)
I also reproduced on 4.03.0.
The text was updated successfully, but these errors were encountered: