From b012c4d31b1e41b4ba76df56d3e5e11251b8769f Mon Sep 17 00:00:00 2001 From: Nicolas Cannasse Date: Mon, 22 Oct 2012 11:06:32 +0000 Subject: [PATCH] 2.11 support --- hscript/Macro.hx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hscript/Macro.hx b/hscript/Macro.hx index f5bfd88..5451c51 100644 --- a/hscript/Macro.hx +++ b/hscript/Macro.hx @@ -159,8 +159,14 @@ class Macro { EIf(convert(c), convert(e1), e2 == null ? null : convert(e2)); case EWhile(c, e): EWhile(convert(c), convert(e), true); + #if (haxe_211 || haxe3) + case EFor(v, it, efor): + var p = #if hscriptPos { file : p.file, min : e.pmin, max : e.pmax } #else p #end; + EFor({ expr : EIn({ expr : EConst(CIdent(v)), pos : p },convert(it)), pos : p }, convert(efor)); + #else case EFor(v, it, e): EFor(v, convert(it), convert(e)); + #end case EBreak: EBreak; case EContinue: