gen-zam: Reserve space for args vector before pushing back items

This commit is contained in:
Tim Wojtulewicz 2025-06-09 17:16:14 -07:00
parent 75bba1a8f5
commit 97492b4d70

View file

@ -2284,6 +2284,7 @@ void ZAM_InternalOpTemplate::ParseCall(const string& line, const Words& words)
}
eval += "auto n = aux->n;\n";
eval += "args.reserve(n);\n";
eval += "for ( auto i = 0; i < n; ++i )\n";
eval += "\targs.push_back(aux->ToVal(frame, i));\n";
}