Tiny refactor

This commit is contained in:
2023-04-25 15:11:20 -06:00
parent 4e44c6cb2d
commit b09346f523

View File

@@ -248,7 +248,8 @@ class Helpers {
var expr = if (body.length == 0) {
EReturn(null).withMacroPosOf(if (name != null) name else argList);
} else {
var block = k.convert(CallExp(Symbol("begin").withPos(body[0].pos), body).withPos(body[0].pos));
var builder = body[0].expBuilder();
var block = k.convert(builder.begin(body));
if (returnsValue) {
EReturn(block).withMacroPosOf(body[-1]);