Skip to content

Commit

Permalink
fix unification error report on TFun with void return
Browse files Browse the repository at this point in the history
  • Loading branch information
Simn committed Oct 10, 2013
1 parent fde7388 commit dcdef91
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion type.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1066,7 +1066,7 @@ let rec unify a b =
let i = ref 0 in
(try
(match r2 with
| TAbstract ({a_path=[],"Void"},_) -> ()
| TAbstract ({a_path=[],"Void"},_) -> incr i
| _ -> unify r1 r2; incr i);
List.iter2 (fun (_,o1,t1) (_,o2,t2) ->
if o1 && not o2 then error [Cant_force_optional];
Expand Down

0 comments on commit dcdef91

Please sign in to comment.