Partial fix (e.g. if (somepointer) but not if (!somepointer)) for issue #5

This commit is contained in:
Joseph Poirier 2015-06-14 15:58:46 -05:00
parent 1ff1ef9cfb
commit 09501d22fd

View file

@ -1907,7 +1907,8 @@ long ExpressionParseInt(struct ParseState *Parser)
ProgramFail(Parser, "expression expected");
if (Parser->Mode == RunModeRun) {
if (!IS_NUMERIC_COERCIBLE(Val))
// if (!IS_NUMERIC_COERCIBLE(Val))
if (!IS_NUMERIC_COERCIBLE_PLUS_POINTERS(Val, true))
ProgramFail(Parser, "integer value expected instead of %t", Val->Typ);
Result = ExpressionCoerceInteger(Val);