From: Jim Meyering Date: Sat, 22 Feb 1997 20:13:19 +0000 (+0000) Subject: (tMONTH_UNIT): Increase yyRelMonth by $1, not just by 1. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2c1196ccedf831086178a2613c80dc6a00f6638d;p=pspp (tMONTH_UNIT): Increase yyRelMonth by $1, not just by 1. (tDAY_UNIT): Likewise for yyRelDay. (tHOUR_UNIT): Likewise for yyRelHour. (tMINUTE_UNIT): Likewise for yyRelMinutes. (tSEC_UNIT): Likewise for yyRelSeconds. --- diff --git a/lib/getdate.y b/lib/getdate.y index d33fa0630f..f63bebfa17 100644 --- a/lib/getdate.y +++ b/lib/getdate.y @@ -356,7 +356,7 @@ relunit : tUNUMBER tYEAR_UNIT { yyRelMonth += $1 * $2; } | tMONTH_UNIT { - yyRelMonth++; + yyRelMonth += $1; } | tUNUMBER tDAY_UNIT { yyRelDay += $1 * $2; @@ -365,7 +365,7 @@ relunit : tUNUMBER tYEAR_UNIT { yyRelDay += $1 * $2; } | tDAY_UNIT { - yyRelDay++; + yyRelDay += $1; } | tUNUMBER tHOUR_UNIT { yyRelHour += $1 * $2; @@ -374,7 +374,7 @@ relunit : tUNUMBER tYEAR_UNIT { yyRelHour += $1 * $2; } | tHOUR_UNIT { - yyRelHour++; + yyRelHour += $1; } | tUNUMBER tMINUTE_UNIT { yyRelMinutes += $1 * $2; @@ -383,7 +383,7 @@ relunit : tUNUMBER tYEAR_UNIT { yyRelMinutes += $1 * $2; } | tMINUTE_UNIT { - yyRelMinutes++; + yyRelMinutes += $1; } | tUNUMBER tSEC_UNIT { yyRelSeconds += $1 * $2; @@ -392,7 +392,7 @@ relunit : tUNUMBER tYEAR_UNIT { yyRelSeconds += $1 * $2; } | tSEC_UNIT { - yyRelSeconds++; + yyRelSeconds += $1; } ;