2
0
Эх сурвалжийг харах

use the same monomorphs for each inline type mapping (see #2874)

Simon Krajewski 11 жил өмнө
parent
commit
aa160e0ef0
1 өөрчлөгдсөн 2 нэмэгдсэн , 1 устгасан
  1. 2 1
      typer.ml

+ 2 - 1
typer.ml

@@ -698,7 +698,8 @@ let make_call ctx e params t p =
 				begin match t with
 					| TAbstract(a,pl) ->
 						let has_params = a.a_types <> [] || f.cf_params <> [] in
-						let map_type = fun t -> apply_params a.a_types pl (monomorphs f.cf_params t) in
+						let monos = List.map (fun _ -> mk_mono()) f.cf_params in
+						let map_type = fun t -> apply_params a.a_types pl (apply_params f.cf_params monos t) in
 						Some (has_params,map_type)
 					| _ ->
 						None