mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 11:43:49 +00:00
Write out variable mapping table to DSO stream, and fix .dump()
This commit is contained in:
parent
9448256422
commit
8d75d60f91
4 changed files with 60 additions and 15 deletions
|
|
@ -1594,10 +1594,12 @@ U32 FunctionDeclStmtNode::compileStmt(CodeStream& codeStream, U32 ip)
|
|||
setCurrentFloatTable(&getGlobalFloatTable());
|
||||
|
||||
// map local variables to registers for this function.
|
||||
// Note we have to map these in order because the table itself is ordered by the register id.
|
||||
CompilerLocalVariableToRegisterMappingTable* tbl = &getFunctionVariableMappingTable();
|
||||
for (const auto& pair : gFuncVars->variableNameMap)
|
||||
for (size_t i = 0; i < gFuncVars->variableNameMap.size(); ++i)
|
||||
{
|
||||
tbl->add(fnName, nameSpace, pair.second, pair.first);
|
||||
StringTableEntry varName = gFuncVars->variableNameMap[i];
|
||||
tbl->add(fnName, nameSpace, varName);
|
||||
}
|
||||
|
||||
gFuncVars = NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue