mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-13 07:57:58 +00:00
Disabled default blocks in mixins for now.
This commit is contained in:
parent
98ee0a7035
commit
a83fff0eb4
1 changed files with 7 additions and 4 deletions
|
@ -268,11 +268,9 @@ void ZCCCompiler::ProcessMixin(ZCC_MixinDef *cnode, PSymbolTreeNode *treenode)
|
||||||
{
|
{
|
||||||
ZCC_MixinWork *cls = new ZCC_MixinWork(cnode, treenode);
|
ZCC_MixinWork *cls = new ZCC_MixinWork(cnode, treenode);
|
||||||
|
|
||||||
Mixins.Push(cls);
|
|
||||||
|
|
||||||
auto node = cnode->Body;
|
auto node = cnode->Body;
|
||||||
|
|
||||||
// Need to check if the class actually has a body.
|
// Need to check if the mixin actually has a body.
|
||||||
if (node != nullptr) do
|
if (node != nullptr) do
|
||||||
{
|
{
|
||||||
if (cnode->MixinType == ZCC_Mixin_Class)
|
if (cnode->MixinType == ZCC_Mixin_Class)
|
||||||
|
@ -288,10 +286,13 @@ void ZCCCompiler::ProcessMixin(ZCC_MixinDef *cnode, PSymbolTreeNode *treenode)
|
||||||
case AST_EnumTerminator:
|
case AST_EnumTerminator:
|
||||||
case AST_States:
|
case AST_States:
|
||||||
case AST_FuncDeclarator:
|
case AST_FuncDeclarator:
|
||||||
case AST_Default:
|
|
||||||
case AST_StaticArrayStatement:
|
case AST_StaticArrayStatement:
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case AST_Default:
|
||||||
|
Error(node, "Default blocks currently disabled in mixins");
|
||||||
|
return;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
assert(0 && "Unhandled AST node type");
|
assert(0 && "Unhandled AST node type");
|
||||||
break;
|
break;
|
||||||
|
@ -300,6 +301,8 @@ void ZCCCompiler::ProcessMixin(ZCC_MixinDef *cnode, PSymbolTreeNode *treenode)
|
||||||
|
|
||||||
node = node->SiblingNext;
|
node = node->SiblingNext;
|
||||||
} while (node != cnode->Body);
|
} while (node != cnode->Body);
|
||||||
|
|
||||||
|
Mixins.Push(cls);
|
||||||
}
|
}
|
||||||
|
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
Loading…
Reference in a new issue