mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 23:12:24 +00:00
- fixed: Deprecation messages should never appear in DECORATE.
- removed some console message spam.
This commit is contained in:
parent
d4ea991763
commit
e50315bd31
4 changed files with 7 additions and 6 deletions
|
@ -73,6 +73,7 @@
|
||||||
#include "vm.h"
|
#include "vm.h"
|
||||||
#include "thingdef.h"
|
#include "thingdef.h"
|
||||||
#include "info.h"
|
#include "info.h"
|
||||||
|
#include "v_text.h"
|
||||||
#include "vmbuilder.h"
|
#include "vmbuilder.h"
|
||||||
|
|
||||||
// [SO] Just the way Randy said to do it :)
|
// [SO] Just the way Randy said to do it :)
|
||||||
|
@ -2108,7 +2109,7 @@ static int PatchCodePtrs (int dummy)
|
||||||
if (!symname.CompareNoCase(MBFCodePointers[i].alias))
|
if (!symname.CompareNoCase(MBFCodePointers[i].alias))
|
||||||
{
|
{
|
||||||
symname = MBFCodePointers[i].name;
|
symname = MBFCodePointers[i].name;
|
||||||
Printf("%s --> %s\n", MBFCodePointers[i].alias, MBFCodePointers[i].name.GetChars());
|
DPrintf(DMSG_SPAMMY, "%s --> %s\n", MBFCodePointers[i].alias, MBFCodePointers[i].name.GetChars());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2117,7 +2118,7 @@ static int PatchCodePtrs (int dummy)
|
||||||
PFunction *sym = dyn_cast<PFunction>(RUNTIME_CLASS(AStateProvider)->Symbols.FindSymbol(symname, true));
|
PFunction *sym = dyn_cast<PFunction>(RUNTIME_CLASS(AStateProvider)->Symbols.FindSymbol(symname, true));
|
||||||
if (sym == NULL)
|
if (sym == NULL)
|
||||||
{
|
{
|
||||||
Printf("Frame %d: Unknown code pointer '%s'\n", frame, Line2);
|
Printf(TEXTCOLOR_RED "Frame %d: Unknown code pointer '%s'\n", frame, Line2);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -2125,7 +2126,7 @@ static int PatchCodePtrs (int dummy)
|
||||||
unsigned numargs = sym->GetImplicitArgs();
|
unsigned numargs = sym->GetImplicitArgs();
|
||||||
if ((sym->Variants[0].Flags & VARF_Virtual || (args.Size() > numargs && !(args[numargs] & VARF_Optional))))
|
if ((sym->Variants[0].Flags & VARF_Virtual || (args.Size() > numargs && !(args[numargs] & VARF_Optional))))
|
||||||
{
|
{
|
||||||
Printf("Frame %d: Incompatible code pointer '%s'\n", frame, Line2);
|
Printf(TEXTCOLOR_RED "Frame %d: Incompatible code pointer '%s'\n", frame, Line2);
|
||||||
sym = NULL;
|
sym = NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4198,7 +4198,7 @@ FxExpression *FxIdentifier::Resolve(FCompileContext& ctx)
|
||||||
// 2. This is a static function
|
// 2. This is a static function
|
||||||
// 3. This is an action function with a restricted self pointer
|
// 3. This is an action function with a restricted self pointer
|
||||||
// 4. This is a normal member or unrestricted action function.
|
// 4. This is a normal member or unrestricted action function.
|
||||||
if (vsym->Flags & VARF_Deprecated)
|
if ((vsym->Flags & VARF_Deprecated) && !ctx.FromDecorate)
|
||||||
{
|
{
|
||||||
ScriptPosition.Message(MSG_WARNING, "Accessing deprecated member variable %s", sym->SymbolName.GetChars());
|
ScriptPosition.Message(MSG_WARNING, "Accessing deprecated member variable %s", sym->SymbolName.GetChars());
|
||||||
}
|
}
|
||||||
|
|
|
@ -202,8 +202,10 @@ void LoadActors ()
|
||||||
FScriptPosition::ResetErrorCounter();
|
FScriptPosition::ResetErrorCounter();
|
||||||
|
|
||||||
InitThingdef();
|
InitThingdef();
|
||||||
|
FScriptPosition::StrictErrors = true;
|
||||||
ParseScripts();
|
ParseScripts();
|
||||||
|
|
||||||
|
FScriptPosition::StrictErrors = false;
|
||||||
ParseAllDecorate();
|
ParseAllDecorate();
|
||||||
|
|
||||||
FunctionBuildList.Build();
|
FunctionBuildList.Build();
|
||||||
|
|
|
@ -1901,7 +1901,6 @@ void ZCCCompiler::InitDefaults()
|
||||||
bag.CurrentState = 0;
|
bag.CurrentState = 0;
|
||||||
bag.Lumpnum = c->cls->SourceLump;
|
bag.Lumpnum = c->cls->SourceLump;
|
||||||
bag.DropItemList = nullptr;
|
bag.DropItemList = nullptr;
|
||||||
bag.ScriptPosition.StrictErrors = true;
|
|
||||||
// The actual script position needs to be set per property.
|
// The actual script position needs to be set per property.
|
||||||
|
|
||||||
for (auto d : c->Defaults)
|
for (auto d : c->Defaults)
|
||||||
|
@ -2425,7 +2424,6 @@ FxExpression *ZCCCompiler::ConvertNode(ZCC_TreeNode *ast)
|
||||||
case AST_ExprMemberAccess:
|
case AST_ExprMemberAccess:
|
||||||
{
|
{
|
||||||
auto ema = static_cast<ZCC_ExprMemberAccess *>(fcall->Function);
|
auto ema = static_cast<ZCC_ExprMemberAccess *>(fcall->Function);
|
||||||
Printf("Member call to %s\n", FName(ema->Right).GetChars());
|
|
||||||
return new FxMemberFunctionCall(ConvertNode(ema->Left), ema->Right, ConvertNodeList(fcall->Parameters), *ast);
|
return new FxMemberFunctionCall(ConvertNode(ema->Left), ema->Right, ConvertNodeList(fcall->Parameters), *ast);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue