From: dtrg Date: Mon, 23 Apr 2007 23:24:46 +0000 (+0000) Subject: Modified to allow a space between the sign and the first digit of a constant. X-Git-Tag: release-6-0-pre-2~9 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=67c4f3de87ccd18a9f2b0ebac811f038bde439d3;p=ack.git Modified to allow a space between the sign and the first digit of a constant. --- diff --git a/modules/src/read_em/reade.c b/modules/src/read_em/reade.c index 69acf2771..f8bf157f8 100644 --- a/modules/src/read_em/reade.c +++ b/modules/src/read_em/reade.c @@ -293,6 +293,11 @@ getnumber(c, ap) c = getbyte(); } + /* Soak up any whitespace (to allow "- 4" to be considered a number). */ + + while (isspace(c)) + c = getbyte(); + if (! isdigit(c)) { ungetbyte(c); syntax("digit expected");