mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 07:12:16 +00:00
Produce a warning if clearscope is used on non-inner structs. Also now checking for outer class presence correctly.
This commit is contained in:
parent
86a494aacd
commit
6af5c1fa2b
1 changed files with 2 additions and 1 deletions
|
@ -501,7 +501,8 @@ void ZCCCompiler::CreateStructTypes()
|
||||||
Error(s->strct, "Struct %s has incompatible flags", s->NodeName().GetChars());
|
Error(s->strct, "Struct %s has incompatible flags", s->NodeName().GetChars());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (outer) s->Type()->ObjectFlags = FScopeBarrier::ChangeSideInObjectFlags(s->Type()->ObjectFlags, FScopeBarrier::SideFromObjectFlags(outer->ObjectFlags));
|
if (outer != OutNamespace) s->Type()->ObjectFlags = FScopeBarrier::ChangeSideInObjectFlags(s->Type()->ObjectFlags, FScopeBarrier::SideFromObjectFlags(outer->ObjectFlags));
|
||||||
|
else if (s->strct->Flags & ZCC_ClearScope) Warn(s->strct, "Useless 'ClearScope' on struct %s not inside a class", s->NodeName().GetChars());
|
||||||
if (s->strct->Flags & ZCC_UIFlag)
|
if (s->strct->Flags & ZCC_UIFlag)
|
||||||
s->Type()->ObjectFlags = FScopeBarrier::ChangeSideInObjectFlags(s->Type()->ObjectFlags, FScopeBarrier::Side_UI);
|
s->Type()->ObjectFlags = FScopeBarrier::ChangeSideInObjectFlags(s->Type()->ObjectFlags, FScopeBarrier::Side_UI);
|
||||||
if (s->strct->Flags & ZCC_Play)
|
if (s->strct->Flags & ZCC_Play)
|
||||||
|
|
Loading…
Reference in a new issue