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

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