소스 검색

don't allow monomorph link Dynamic.

Nicolas Cannasse 19 년 전
부모
커밋
97e2cc5903
1개의 변경된 파일4개의 추가작업 그리고 4개의 파일을 삭제
  1. 4 4
      type.ml

+ 4 - 4
type.ml

@@ -254,10 +254,10 @@ let rec link e a b =
 	in
 	in
 	if loop b then
 	if loop b then
 		false
 		false
-	else begin
-		e := Some b;
-		true
-	end
+	else
+		match b with
+		| TDynamic _ -> true
+		| _ -> e := Some b; true
 
 
 (* substitute parameters with other types *)
 (* substitute parameters with other types *)
 let apply_params cparams params t =
 let apply_params cparams params t =