浏览代码

disable deprecation warning upon returning Type from `@:genericBuild` macro

Simon Krajewski 11 年之前
父节点
当前提交
0625d1e2c1
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      typer.ml

+ 2 - 1
typer.ml

@@ -4420,7 +4420,8 @@ let type_macro ctx mode cpath f (el:Ast.expr list) p =
 		let ttype = Typeload.load_instance mctx cttype p false in
 		try
 			unify_raise mctx mret ttype mpos;
-			ctx.com.warning "Returning Type from @:genericBuild macros is deprecated, consider returning ComplexType instead" p;
+			(* TODO: enable this again in the future *)
+			(* ctx.com.warning "Returning Type from @:genericBuild macros is deprecated, consider returning ComplexType instead" p; *)
 		with Error (Unify _,_) ->
 			let cttype = { tpackage = ["haxe";"macro"]; tname = "Expr"; tparams = []; tsub = Some ("ComplexType") } in
 			let ttype = Typeload.load_instance mctx cttype p false in