Issue error when declaration rule fails

Fix #2514.
This commit is contained in:
Jeremy Hayes 2021-04-09 16:37:20 -06:00
parent 9f76fd1330
commit 4b900778c3
2 changed files with 5 additions and 2 deletions

View file

@ -161,8 +161,10 @@ bool HlslGrammar::acceptDeclarationList(TIntermNode*& nodeList)
return true;
// declaration
if (! acceptDeclaration(nodeList))
if (! acceptDeclaration(nodeList)) {
expected("declaration");
return false;
}
} while (true);
return true;