* getdate.y (yylex): Allow space between sign and number.
authorPaul Eggert <eggert@cs.ucla.edu>
Sun, 6 Jun 2004 18:55:59 +0000 (18:55 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Sun, 6 Jun 2004 18:55:59 +0000 (18:55 +0000)
lib/ChangeLog
lib/getdate.y

index 32b69d2243081373cf6d122c74d416aac4b92fd8..ce8dbf26cfb977388f8a878b5d60543dbc7e7be8 100644 (file)
@@ -1,3 +1,8 @@
+2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
+
+       * getdate.y (yylex): Allow space between sign and number.
+       Problem reported by Dan Jacobson.
+
 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
        and  Jim Meyering  <jim@meyering.net>
 
index 52ed8530ba64fdf59e4de885e11f03ed2262ec27..5784b6ccdc9bad4e44fd9478633bd09838512699 100644 (file)
@@ -844,7 +844,8 @@ yylex (YYSTYPE *lvalp, parser_control *pc)
          if (c == '-' || c == '+')
            {
              sign = c == '-' ? -1 : 1;
-             c = *++pc->input;
+             while (c = *++pc->input, ISSPACE (c))
+               continue;
              if (! ISDIGIT (c))
                /* skip the '-' sign */
                continue;