Fix &opt bug in defMacro

This commit is contained in:
2023-04-06 08:24:19 -06:00
parent 291075e980
commit 583383cc62

View File

@@ -494,8 +494,11 @@ class Macros {
}
macroCallForm += ')';
if (optIndex == -1)
if (optIndex == -1) {
optIndex = minArgs;
} else if (restIndex == -1) {
restIndex = optIndex + 1;
}
if (restIndex == -1)
restIndex = optIndex;