mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-07 13:31:08 +00:00
Update astNodes.cpp
strings that are arguments for a function need to be put into the global string table. PrecompileIdent does this for the function name etc so it pulls from that during compiled eval
This commit is contained in:
parent
6e96c0510d
commit
3a4e2f8a7e
|
|
@ -1529,6 +1529,7 @@ U32 FunctionDeclStmtNode::compileStmt(CodeStream& codeStream, U32 ip)
|
|||
|
||||
CodeBlock::smInFunction = false;
|
||||
|
||||
setCurrentStringTable(&getGlobalStringTable());
|
||||
// check for argument setup
|
||||
for (VarNode* walk = args; walk; walk = (VarNode*)((StmtNode*)walk)->getNext())
|
||||
{
|
||||
|
|
@ -1541,6 +1542,7 @@ U32 FunctionDeclStmtNode::compileStmt(CodeStream& codeStream, U32 ip)
|
|||
ip = walk->defaultValue->compile(codeStream, ip, walkType);
|
||||
}
|
||||
}
|
||||
setCurrentStringTable(&getFunctionStringTable());
|
||||
|
||||
codeStream.emit(OP_FUNC_DECL);
|
||||
codeStream.emitSTE(fnName);
|
||||
|
|
|
|||
Loading…
Reference in a new issue