瀏覽代碼

fixed constructor return type

Nicolas Cannasse 18 年之前
父節點
當前提交
c85f5de385
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      typer.ml

+ 1 - 1
typer.ml

@@ -2363,7 +2363,7 @@ let init_class ctx c p herits fields =
 			let eargs = List.map (fun (n,_,t) -> mk (TLocal n) t p) args in
 			let eargs = List.map (fun (n,_,t) -> mk (TLocal n) t p) args in
 			let func = {
 			let func = {
 				tf_args = args;
 				tf_args = args;
-				tf_type = t;
+				tf_type = t_void ctx;
 				tf_expr = mk (TCall (mk (TConst TSuper) (TInst (csuper,cparams)) p,eargs)) r p;
 				tf_expr = mk (TCall (mk (TConst TSuper) (TInst (csuper,cparams)) p,eargs)) r p;
 			} in
 			} in
 			c.cl_constructor <- Some {
 			c.cl_constructor <- Some {