fix limited_generalize for variants
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@6620 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02master
parent
695fe90650
commit
281e9b9867
|
@ -678,7 +678,13 @@ let limited_generalize ty0 ty =
|
|||
let idx = ty.level in
|
||||
if idx <> generic_level then begin
|
||||
set_level ty generic_level;
|
||||
List.iter generalize_parents !(snd (Hashtbl.find graph idx))
|
||||
List.iter generalize_parents !(snd (Hashtbl.find graph idx));
|
||||
(* Special case for rows: must generalize the row variable *)
|
||||
match ty.desc with
|
||||
Tvariant row ->
|
||||
let more = row_more row in
|
||||
if more.level <> generic_level then generalize_parents more
|
||||
| _ -> ()
|
||||
end
|
||||
in
|
||||
|
||||
|
|
Loading…
Reference in New Issue