Add an error check after calling doexpr2().

This commit is contained in:
David Anderson 2014-11-08 03:07:34 -08:00
parent 512cbc73a0
commit dbee1bcd08

View File

@ -2206,6 +2206,17 @@ static void declloc(int tokid)
&type->idxtag[i],
&child, 0, &val);
pushreg(sPRI);
switch (ident) {
case iVARIABLE:
case iEXPRESSION:
case iARRAYCELL:
case iCONSTEXPR:
break;
default:
error(29);
break;
}
if (!needtoken(']'))
break;