diff --git a/kiss/src/kiss/Kiss.hx b/kiss/src/kiss/Kiss.hx index df44f4a0..1b5f3390 100644 --- a/kiss/src/kiss/Kiss.hx +++ b/kiss/src/kiss/Kiss.hx @@ -223,8 +223,11 @@ class Kiss { } // When calling from build(), we can't add all expressions to the (begin) returned by (load), because that will // cause double-evaluation of field forms - if (loadAllExps || !isEmpty(expr)) { + if (loadAllExps) { loadedExps.push(nextExp); + } else if (!isEmpty(expr)) { + // don't double-compile macros: + loadedExps.push(RawHaxe(expr.toString()).withPosOf(nextExp)); } }); diff --git a/projects/pdf-salad/src/Main.kiss b/projects/pdf-salad/src/Main.kiss index 89c8cbce..34416bfb 100644 --- a/projects/pdf-salad/src/Main.kiss +++ b/projects/pdf-salad/src/Main.kiss @@ -24,4 +24,4 @@ (saladPdf.copyPages pdf [page]))))] (doFor page pages (saladPdf.addPage (first page))) (awaitLet [bytesOut (saladPdf.save)] - (Fs.writeFileSync "out.pdf" bytesOut)))))) + (Fs.writeFileSync "out.pdf" bytesOut)))))) \ No newline at end of file