浏览代码

improved $i reification (fixed issue #1549)

Nicolas Cannasse 12 年之前
父节点
当前提交
c4cd46e2bf
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      ast.ml

+ 1 - 1
ast.ml

@@ -1103,7 +1103,7 @@ let reify in_macro =
 				expr "EBlock" [e1]
 			(* TODO: can $v and $i be implemented better? *)
 			| Meta.Dollar "v", _ ->
-				(ECall ((EField ((EField ((EField ((EConst (Ident "haxe"),p),"macro"),p),"Context"),p),"makeExpr"),p),[e; to_pos (pos e)]),p)
+				expr "EConst" [mk_enum "Constant" "CIdent" [e1] (pos e1)]
 			| Meta.Dollar "i", _ ->
 				(ECall ((EField ((EField ((EField ((EConst (Ident "haxe"),p),"macro"),p),"ExprTools"),p),"asIdent"),p),[e; to_pos (pos e)]),p)
 			| Meta.Dollar "p", _ ->