mirror of
https://github.com/ZDoom/Raze.git
synced 2025-05-31 09:20:59 +00:00
- allocate VMFunction's PrintableName from the ClassDataAllocator arena.
This avoids execution order issues on shutdown. VMFunction should not use FString.
This commit is contained in:
parent
7d30f1921c
commit
213bdbadad
15 changed files with 28 additions and 20 deletions
|
@ -9151,7 +9151,7 @@ FxExpression *FxVMFunctionCall::Resolve(FCompileContext& ctx)
|
|||
// [Player701] Catch attempts to call abstract functions directly at compile time
|
||||
if (NoVirtual && Function->Variants[0].Implementation->VarFlags & VARF_Abstract)
|
||||
{
|
||||
ScriptPosition.Message(MSG_ERROR, "Cannot call abstract function %s", Function->Variants[0].Implementation->PrintableName.GetChars());
|
||||
ScriptPosition.Message(MSG_ERROR, "Cannot call abstract function %s", Function->Variants[0].Implementation->PrintableName);
|
||||
delete this;
|
||||
return nullptr;
|
||||
}
|
||||
|
|
|
@ -790,7 +790,7 @@ VMFunction *FFunctionBuildList::AddFunction(PNamespace *gnspc, const VersionInfo
|
|||
it.PrintableName = name;
|
||||
it.Function = new VMScriptFunction;
|
||||
it.Function->Name = functype->SymbolName;
|
||||
it.Function->PrintableName = name;
|
||||
it.Function->PrintableName = ClassDataAllocator.Strdup(name);
|
||||
it.Function->ImplicitArgs = functype->GetImplicitArgs();
|
||||
it.Proto = nullptr;
|
||||
it.FromDecorate = fromdecorate;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue