-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Unclear error message in 4.01.0 #6295
Copy link
Copy link
Closed
Description
Original bug ID: 6295
Reporter: @dbuenzli
Status: closed (set by @gasche on 2014-01-17T09:03:08Z)
Resolution: duplicate
Priority: normal
Severity: minor
Version: 4.01.0
Category: ~DO NOT USE (was: OCaml general)
Duplicate of: #6173
Monitored by: @hcarty @dbuenzli
Bug description
For the following (wrong) code,
> opam-switch-eval 4.01.0
> ocaml
OCaml version 4.01.0
# let _ =
try
while true do if true then raise Exit done
with Exit -> 1 :: []
;;
Error: The variant type unit has no constructor ::
the error message was much clearer in 4.00.1:
> opam-switch-eval 4.00.1
> ocaml
OCaml version 4.00.1
# let _ =
try
while true do if true then raise Exit done
with Exit -> 1 :: []
;;
Error: This expression has type 'a list
but an expression was expected of type unit
Reactions are currently unavailable