mirror of
https://github.com/php/php-src.git
synced 2024-09-21 18:07:23 +00:00
Some (old, backwards compatible) TZIDs can have numbers in them
This commit is contained in:
parent
64f5f5333e
commit
c87c803b96
@ -1,4 +1,4 @@
|
||||
/* Generated by re2c 0.15.3 on Wed Nov 30 11:53:33 2022 */
|
||||
/* Generated by re2c 0.15.3 on Thu Dec 1 10:57:42 2022 */
|
||||
#line 1 "ext/date/lib/parse_date.re"
|
||||
/*
|
||||
* The MIT License (MIT)
|
||||
@ -756,10 +756,11 @@ static timelib_long timelib_lookup_abbr(const char **ptr, int *dst, char **tz_ab
|
||||
timelib_long value = 0;
|
||||
const timelib_tz_lookup_table *tp;
|
||||
|
||||
/* Only include A-Z, a-z, /, _, and - in abbreviations/TZ IDs */
|
||||
/* Only include A-Z, a-z, 0-9, /, _, and - in abbreviations/TZ IDs */
|
||||
while (
|
||||
(**ptr >= 'A' && **ptr <= 'Z') ||
|
||||
(**ptr >= 'a' && **ptr <= 'z') ||
|
||||
(**ptr >= '0' && **ptr <= '9') ||
|
||||
**ptr == '/' || **ptr == '_' || **ptr == '-'
|
||||
) {
|
||||
++*ptr;
|
||||
@ -957,11 +958,11 @@ static int scan(Scanner *s, timelib_tz_get_wrapper tz_get_wrapper)
|
||||
std:
|
||||
s->tok = cursor;
|
||||
s->len = 0;
|
||||
#line 1088 "ext/date/lib/parse_date.re"
|
||||
#line 1089 "ext/date/lib/parse_date.re"
|
||||
|
||||
|
||||
|
||||
#line 965 "<stdout>"
|
||||
#line 966 "<stdout>"
|
||||
{
|
||||
YYCTYPE yych;
|
||||
unsigned int yyaccept = 0;
|
||||
@ -1099,7 +1100,7 @@ yy2:
|
||||
}
|
||||
yy3:
|
||||
YYDEBUG(3, *YYCURSOR);
|
||||
#line 1822 "ext/date/lib/parse_date.re"
|
||||
#line 1823 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int tz_not_found;
|
||||
DEBUG_OUTPUT("tzcorrection | tz");
|
||||
@ -1112,7 +1113,7 @@ yy3:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_TIMEZONE;
|
||||
}
|
||||
#line 1116 "<stdout>"
|
||||
#line 1117 "<stdout>"
|
||||
yy4:
|
||||
YYDEBUG(4, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -1419,12 +1420,12 @@ yy11:
|
||||
if (yych <= '9') goto yy1483;
|
||||
yy12:
|
||||
YYDEBUG(12, *YYCURSOR);
|
||||
#line 1917 "ext/date/lib/parse_date.re"
|
||||
#line 1918 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
add_error(s, TIMELIB_ERR_UNEXPECTED_CHARACTER, "Unexpected character");
|
||||
goto std;
|
||||
}
|
||||
#line 1428 "<stdout>"
|
||||
#line 1429 "<stdout>"
|
||||
yy13:
|
||||
YYDEBUG(13, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -2668,11 +2669,11 @@ yy48:
|
||||
if (yych <= '9') goto yy54;
|
||||
yy49:
|
||||
YYDEBUG(49, *YYCURSOR);
|
||||
#line 1906 "ext/date/lib/parse_date.re"
|
||||
#line 1907 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
goto std;
|
||||
}
|
||||
#line 2676 "<stdout>"
|
||||
#line 2677 "<stdout>"
|
||||
yy50:
|
||||
YYDEBUG(50, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -2681,12 +2682,12 @@ yy51:
|
||||
YYDEBUG(51, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(52, *YYCURSOR);
|
||||
#line 1911 "ext/date/lib/parse_date.re"
|
||||
#line 1912 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
s->pos = cursor; s->line++;
|
||||
goto std;
|
||||
}
|
||||
#line 2690 "<stdout>"
|
||||
#line 2691 "<stdout>"
|
||||
yy53:
|
||||
YYDEBUG(53, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -3108,7 +3109,7 @@ yy83:
|
||||
if (yych == 's') goto yy85;
|
||||
yy84:
|
||||
YYDEBUG(84, *YYCURSOR);
|
||||
#line 1890 "ext/date/lib/parse_date.re"
|
||||
#line 1891 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_ull i;
|
||||
DEBUG_OUTPUT("relative");
|
||||
@ -3123,7 +3124,7 @@ yy84:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 3127 "<stdout>"
|
||||
#line 3128 "<stdout>"
|
||||
yy85:
|
||||
YYDEBUG(85, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -4132,7 +4133,7 @@ yy218:
|
||||
}
|
||||
yy219:
|
||||
YYDEBUG(219, *YYCURSOR);
|
||||
#line 1753 "ext/date/lib/parse_date.re"
|
||||
#line 1754 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
const timelib_relunit* relunit;
|
||||
DEBUG_OUTPUT("daytext");
|
||||
@ -4149,7 +4150,7 @@ yy219:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_WEEKDAY;
|
||||
}
|
||||
#line 4153 "<stdout>"
|
||||
#line 4154 "<stdout>"
|
||||
yy220:
|
||||
YYDEBUG(220, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -4695,7 +4696,7 @@ yy247:
|
||||
}
|
||||
yy248:
|
||||
YYDEBUG(248, *YYCURSOR);
|
||||
#line 1812 "ext/date/lib/parse_date.re"
|
||||
#line 1813 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("monthtext");
|
||||
TIMELIB_INIT;
|
||||
@ -4704,7 +4705,7 @@ yy248:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_TEXT;
|
||||
}
|
||||
#line 4708 "<stdout>"
|
||||
#line 4709 "<stdout>"
|
||||
yy249:
|
||||
YYDEBUG(249, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
@ -4953,7 +4954,7 @@ yy261:
|
||||
goto yy267;
|
||||
yy262:
|
||||
YYDEBUG(262, *YYCURSOR);
|
||||
#line 1558 "ext/date/lib/parse_date.re"
|
||||
#line 1559 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("datetextual | datenoyear");
|
||||
@ -4966,7 +4967,7 @@ yy262:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_TEXT;
|
||||
}
|
||||
#line 4970 "<stdout>"
|
||||
#line 4971 "<stdout>"
|
||||
yy263:
|
||||
YYDEBUG(263, *YYCURSOR);
|
||||
yyaccept = 6;
|
||||
@ -5093,7 +5094,7 @@ yy275:
|
||||
}
|
||||
yy276:
|
||||
YYDEBUG(276, *YYCURSOR);
|
||||
#line 1860 "ext/date/lib/parse_date.re"
|
||||
#line 1861 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int tz_not_found;
|
||||
DEBUG_OUTPUT("dateshortwithtimeshort | dateshortwithtimelong | dateshortwithtimelongtz");
|
||||
@ -5122,7 +5123,7 @@ yy276:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_SHORTDATE_WITH_TIME;
|
||||
}
|
||||
#line 5126 "<stdout>"
|
||||
#line 5127 "<stdout>"
|
||||
yy277:
|
||||
YYDEBUG(277, *YYCURSOR);
|
||||
yyaccept = 7;
|
||||
@ -5420,7 +5421,7 @@ yy300:
|
||||
YYDEBUG(300, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(301, *YYCURSOR);
|
||||
#line 1836 "ext/date/lib/parse_date.re"
|
||||
#line 1837 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("dateshortwithtimeshort12 | dateshortwithtimelong12");
|
||||
TIMELIB_INIT;
|
||||
@ -5443,7 +5444,7 @@ yy300:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_SHORTDATE_WITH_TIME;
|
||||
}
|
||||
#line 5447 "<stdout>"
|
||||
#line 5448 "<stdout>"
|
||||
yy302:
|
||||
YYDEBUG(302, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -6121,7 +6122,7 @@ yy361:
|
||||
YYDEBUG(362, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(363, *YYCURSOR);
|
||||
#line 1530 "ext/date/lib/parse_date.re"
|
||||
#line 1531 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("datenoday");
|
||||
@ -6134,7 +6135,7 @@ yy361:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_NO_DAY;
|
||||
}
|
||||
#line 6138 "<stdout>"
|
||||
#line 6139 "<stdout>"
|
||||
yy364:
|
||||
YYDEBUG(364, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -6365,7 +6366,7 @@ yy368:
|
||||
if (yych <= '9') goto yy372;
|
||||
yy371:
|
||||
YYDEBUG(371, *YYCURSOR);
|
||||
#line 1674 "ext/date/lib/parse_date.re"
|
||||
#line 1675 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("pgtextshort");
|
||||
@ -6378,7 +6379,7 @@ yy371:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_PG_TEXT;
|
||||
}
|
||||
#line 6382 "<stdout>"
|
||||
#line 6383 "<stdout>"
|
||||
yy372:
|
||||
YYDEBUG(372, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -6960,7 +6961,7 @@ yy397:
|
||||
}
|
||||
yy398:
|
||||
YYDEBUG(398, *YYCURSOR);
|
||||
#line 1732 "ext/date/lib/parse_date.re"
|
||||
#line 1733 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("ago");
|
||||
TIMELIB_INIT;
|
||||
@ -6980,7 +6981,7 @@ yy398:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_AGO;
|
||||
}
|
||||
#line 6984 "<stdout>"
|
||||
#line 6985 "<stdout>"
|
||||
yy399:
|
||||
YYDEBUG(399, *YYCURSOR);
|
||||
yyaccept = 5;
|
||||
@ -8769,7 +8770,7 @@ yy460:
|
||||
++YYCURSOR;
|
||||
yy461:
|
||||
YYDEBUG(461, *YYCURSOR);
|
||||
#line 1423 "ext/date/lib/parse_date.re"
|
||||
#line 1424 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("iso8601date4 | iso8601date2 | iso8601dateslash | dateslash");
|
||||
TIMELIB_INIT;
|
||||
@ -8780,7 +8781,7 @@ yy461:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_DATE;
|
||||
}
|
||||
#line 8784 "<stdout>"
|
||||
#line 8785 "<stdout>"
|
||||
yy462:
|
||||
YYDEBUG(462, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -8902,7 +8903,7 @@ yy484:
|
||||
YYDEBUG(484, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(485, *YYCURSOR);
|
||||
#line 1449 "ext/date/lib/parse_date.re"
|
||||
#line 1450 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("iso8601datex");
|
||||
TIMELIB_INIT;
|
||||
@ -8913,7 +8914,7 @@ yy484:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_DATE;
|
||||
}
|
||||
#line 8917 "<stdout>"
|
||||
#line 8918 "<stdout>"
|
||||
yy486:
|
||||
YYDEBUG(486, *YYCURSOR);
|
||||
yyaccept = 1;
|
||||
@ -9667,7 +9668,7 @@ yy508:
|
||||
}
|
||||
yy509:
|
||||
YYDEBUG(509, *YYCURSOR);
|
||||
#line 1572 "ext/date/lib/parse_date.re"
|
||||
#line 1573 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("datenoyearrev");
|
||||
TIMELIB_INIT;
|
||||
@ -9678,7 +9679,7 @@ yy509:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_TEXT;
|
||||
}
|
||||
#line 9682 "<stdout>"
|
||||
#line 9683 "<stdout>"
|
||||
yy510:
|
||||
YYDEBUG(510, *YYCURSOR);
|
||||
yyaccept = 9;
|
||||
@ -9819,7 +9820,7 @@ yy521:
|
||||
YYDEBUG(521, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(522, *YYCURSOR);
|
||||
#line 1276 "ext/date/lib/parse_date.re"
|
||||
#line 1277 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("timetiny12 | timeshort12 | timelong12");
|
||||
TIMELIB_INIT;
|
||||
@ -9835,7 +9836,7 @@ yy521:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_TIME12;
|
||||
}
|
||||
#line 9839 "<stdout>"
|
||||
#line 9840 "<stdout>"
|
||||
yy523:
|
||||
YYDEBUG(523, *YYCURSOR);
|
||||
yyaccept = 10;
|
||||
@ -9848,7 +9849,7 @@ yy523:
|
||||
}
|
||||
yy524:
|
||||
YYDEBUG(524, *YYCURSOR);
|
||||
#line 1313 "ext/date/lib/parse_date.re"
|
||||
#line 1314 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int tz_not_found;
|
||||
DEBUG_OUTPUT("timetiny24 | timeshort24 | timelong24 | iso8601long");
|
||||
@ -9875,7 +9876,7 @@ yy524:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_TIME24_WITH_ZONE;
|
||||
}
|
||||
#line 9879 "<stdout>"
|
||||
#line 9880 "<stdout>"
|
||||
yy525:
|
||||
YYDEBUG(525, *YYCURSOR);
|
||||
yyaccept = 10;
|
||||
@ -10188,7 +10189,7 @@ yy556:
|
||||
YYDEBUG(556, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(557, *YYCURSOR);
|
||||
#line 1293 "ext/date/lib/parse_date.re"
|
||||
#line 1294 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("mssqltime");
|
||||
TIMELIB_INIT;
|
||||
@ -10207,7 +10208,7 @@ yy556:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_TIME24_WITH_ZONE;
|
||||
}
|
||||
#line 10211 "<stdout>"
|
||||
#line 10212 "<stdout>"
|
||||
yy558:
|
||||
YYDEBUG(558, *YYCURSOR);
|
||||
yyaccept = 10;
|
||||
@ -10313,7 +10314,7 @@ yy567:
|
||||
if (yych <= '9') goto yy574;
|
||||
yy568:
|
||||
YYDEBUG(568, *YYCURSOR);
|
||||
#line 1489 "ext/date/lib/parse_date.re"
|
||||
#line 1490 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("datefull");
|
||||
@ -10327,7 +10328,7 @@ yy568:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_FULL;
|
||||
}
|
||||
#line 10331 "<stdout>"
|
||||
#line 10332 "<stdout>"
|
||||
yy569:
|
||||
YYDEBUG(569, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -11063,7 +11064,7 @@ yy638:
|
||||
YYDEBUG(639, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(640, *YYCURSOR);
|
||||
#line 1504 "ext/date/lib/parse_date.re"
|
||||
#line 1505 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("pointed date YYYY");
|
||||
TIMELIB_INIT;
|
||||
@ -11074,7 +11075,7 @@ yy638:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_FULL_POINTED;
|
||||
}
|
||||
#line 11078 "<stdout>"
|
||||
#line 11079 "<stdout>"
|
||||
yy641:
|
||||
YYDEBUG(641, *YYCURSOR);
|
||||
yyaccept = 10;
|
||||
@ -11110,7 +11111,7 @@ yy644:
|
||||
if (yych <= '9') goto yy638;
|
||||
yy645:
|
||||
YYDEBUG(645, *YYCURSOR);
|
||||
#line 1516 "ext/date/lib/parse_date.re"
|
||||
#line 1517 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("pointed date YY");
|
||||
@ -11123,7 +11124,7 @@ yy645:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_FULL_POINTED;
|
||||
}
|
||||
#line 11127 "<stdout>"
|
||||
#line 11128 "<stdout>"
|
||||
yy646:
|
||||
YYDEBUG(646, *YYCURSOR);
|
||||
yyaccept = 10;
|
||||
@ -11764,7 +11765,7 @@ yy689:
|
||||
}
|
||||
yy690:
|
||||
YYDEBUG(690, *YYCURSOR);
|
||||
#line 1475 "ext/date/lib/parse_date.re"
|
||||
#line 1476 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("gnudateshort");
|
||||
@ -11777,7 +11778,7 @@ yy690:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_DATE;
|
||||
}
|
||||
#line 11781 "<stdout>"
|
||||
#line 11782 "<stdout>"
|
||||
yy691:
|
||||
YYDEBUG(691, *YYCURSOR);
|
||||
yyaccept = 12;
|
||||
@ -11883,7 +11884,7 @@ yy699:
|
||||
}
|
||||
yy700:
|
||||
YYDEBUG(700, *YYCURSOR);
|
||||
#line 1407 "ext/date/lib/parse_date.re"
|
||||
#line 1408 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("americanshort | american");
|
||||
@ -11898,7 +11899,7 @@ yy700:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_AMERICAN;
|
||||
}
|
||||
#line 11902 "<stdout>"
|
||||
#line 11903 "<stdout>"
|
||||
yy701:
|
||||
YYDEBUG(701, *YYCURSOR);
|
||||
yyaccept = 13;
|
||||
@ -12132,7 +12133,7 @@ yy733:
|
||||
if (yych <= ':') goto yy737;
|
||||
yy734:
|
||||
YYDEBUG(734, *YYCURSOR);
|
||||
#line 1702 "ext/date/lib/parse_date.re"
|
||||
#line 1703 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int tz_not_found;
|
||||
DEBUG_OUTPUT("clf");
|
||||
@ -12152,7 +12153,7 @@ yy734:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_CLF;
|
||||
}
|
||||
#line 12156 "<stdout>"
|
||||
#line 12157 "<stdout>"
|
||||
yy735:
|
||||
YYDEBUG(735, *YYCURSOR);
|
||||
yyaccept = 14;
|
||||
@ -12772,7 +12773,7 @@ yy807:
|
||||
}
|
||||
yy808:
|
||||
YYDEBUG(808, *YYCURSOR);
|
||||
#line 1435 "ext/date/lib/parse_date.re"
|
||||
#line 1436 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("iso8601date2");
|
||||
@ -12785,7 +12786,7 @@ yy808:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_DATE;
|
||||
}
|
||||
#line 12789 "<stdout>"
|
||||
#line 12790 "<stdout>"
|
||||
yy809:
|
||||
YYDEBUG(809, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -12824,7 +12825,7 @@ yy815:
|
||||
YYDEBUG(815, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(816, *YYCURSOR);
|
||||
#line 1688 "ext/date/lib/parse_date.re"
|
||||
#line 1689 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("pgtextreverse");
|
||||
@ -12837,7 +12838,7 @@ yy815:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_PG_TEXT;
|
||||
}
|
||||
#line 12841 "<stdout>"
|
||||
#line 12842 "<stdout>"
|
||||
yy817:
|
||||
YYDEBUG(817, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -13002,7 +13003,7 @@ yy827:
|
||||
}
|
||||
yy828:
|
||||
YYDEBUG(828, *YYCURSOR);
|
||||
#line 1723 "ext/date/lib/parse_date.re"
|
||||
#line 1724 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("year4");
|
||||
TIMELIB_INIT;
|
||||
@ -13010,7 +13011,7 @@ yy828:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_CLF;
|
||||
}
|
||||
#line 13014 "<stdout>"
|
||||
#line 13015 "<stdout>"
|
||||
yy829:
|
||||
YYDEBUG(829, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -13215,7 +13216,7 @@ yy837:
|
||||
}
|
||||
yy838:
|
||||
YYDEBUG(838, *YYCURSOR);
|
||||
#line 1544 "ext/date/lib/parse_date.re"
|
||||
#line 1545 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("datenodayrev");
|
||||
@ -13228,7 +13229,7 @@ yy838:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_NO_DAY;
|
||||
}
|
||||
#line 13232 "<stdout>"
|
||||
#line 13233 "<stdout>"
|
||||
yy839:
|
||||
YYDEBUG(839, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -13449,7 +13450,7 @@ yy858:
|
||||
if (yych <= '7') goto yy861;
|
||||
yy859:
|
||||
YYDEBUG(859, *YYCURSOR);
|
||||
#line 1655 "ext/date/lib/parse_date.re"
|
||||
#line 1656 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_sll w, d;
|
||||
DEBUG_OUTPUT("isoweek");
|
||||
@ -13467,7 +13468,7 @@ yy859:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_WEEK;
|
||||
}
|
||||
#line 13471 "<stdout>"
|
||||
#line 13472 "<stdout>"
|
||||
yy860:
|
||||
YYDEBUG(860, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -13477,7 +13478,7 @@ yy861:
|
||||
YYDEBUG(861, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(862, *YYCURSOR);
|
||||
#line 1636 "ext/date/lib/parse_date.re"
|
||||
#line 1637 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_sll w, d;
|
||||
DEBUG_OUTPUT("isoweekday");
|
||||
@ -13495,7 +13496,7 @@ yy861:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_WEEK;
|
||||
}
|
||||
#line 13499 "<stdout>"
|
||||
#line 13500 "<stdout>"
|
||||
yy863:
|
||||
YYDEBUG(863, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -13567,7 +13568,7 @@ yy865:
|
||||
}
|
||||
yy866:
|
||||
YYDEBUG(866, *YYCURSOR);
|
||||
#line 1622 "ext/date/lib/parse_date.re"
|
||||
#line 1623 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("pgydotd");
|
||||
@ -13580,7 +13581,7 @@ yy866:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_PG_YEARDAY;
|
||||
}
|
||||
#line 13584 "<stdout>"
|
||||
#line 13585 "<stdout>"
|
||||
yy867:
|
||||
YYDEBUG(867, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -13683,7 +13684,7 @@ yy886:
|
||||
++YYCURSOR;
|
||||
yy887:
|
||||
YYDEBUG(887, *YYCURSOR);
|
||||
#line 1596 "ext/date/lib/parse_date.re"
|
||||
#line 1597 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int tz_not_found;
|
||||
DEBUG_OUTPUT("xmlrpc | xmlrpcnocolon | soap | wddx | exif");
|
||||
@ -13708,7 +13709,7 @@ yy887:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_XMLRPC_SOAP;
|
||||
}
|
||||
#line 13712 "<stdout>"
|
||||
#line 13713 "<stdout>"
|
||||
yy888:
|
||||
YYDEBUG(888, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -14004,7 +14005,7 @@ yy892:
|
||||
}
|
||||
yy893:
|
||||
YYDEBUG(893, *YYCURSOR);
|
||||
#line 1584 "ext/date/lib/parse_date.re"
|
||||
#line 1585 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("datenocolon");
|
||||
TIMELIB_INIT;
|
||||
@ -14015,7 +14016,7 @@ yy893:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_DATE_NOCOLON;
|
||||
}
|
||||
#line 14019 "<stdout>"
|
||||
#line 14020 "<stdout>"
|
||||
yy894:
|
||||
YYDEBUG(894, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -14937,7 +14938,7 @@ yy1017:
|
||||
}
|
||||
yy1018:
|
||||
YYDEBUG(1018, *YYCURSOR);
|
||||
#line 1461 "ext/date/lib/parse_date.re"
|
||||
#line 1462 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int length = 0;
|
||||
DEBUG_OUTPUT("gnudateshorter");
|
||||
@ -14950,7 +14951,7 @@ yy1018:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_DATE;
|
||||
}
|
||||
#line 14954 "<stdout>"
|
||||
#line 14955 "<stdout>"
|
||||
yy1019:
|
||||
YYDEBUG(1019, *YYCURSOR);
|
||||
yyaccept = 22;
|
||||
@ -16158,7 +16159,7 @@ yy1125:
|
||||
}
|
||||
yy1127:
|
||||
YYDEBUG(1127, *YYCURSOR);
|
||||
#line 1341 "ext/date/lib/parse_date.re"
|
||||
#line 1342 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("gnunocolon");
|
||||
TIMELIB_INIT;
|
||||
@ -16180,7 +16181,7 @@ yy1127:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_GNU_NOCOLON;
|
||||
}
|
||||
#line 16184 "<stdout>"
|
||||
#line 16185 "<stdout>"
|
||||
yy1128:
|
||||
YYDEBUG(1128, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -16280,7 +16281,7 @@ yy1134:
|
||||
}
|
||||
yy1135:
|
||||
YYDEBUG(1135, *YYCURSOR);
|
||||
#line 1387 "ext/date/lib/parse_date.re"
|
||||
#line 1388 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
int tz_not_found;
|
||||
DEBUG_OUTPUT("iso8601nocolon");
|
||||
@ -16299,7 +16300,7 @@ yy1135:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_ISO_NOCOLON;
|
||||
}
|
||||
#line 16303 "<stdout>"
|
||||
#line 16304 "<stdout>"
|
||||
yy1136:
|
||||
YYDEBUG(1136, *YYCURSOR);
|
||||
yyaccept = 25;
|
||||
@ -17275,7 +17276,7 @@ yy1178:
|
||||
}
|
||||
yy1179:
|
||||
YYDEBUG(1179, *YYCURSOR);
|
||||
#line 1795 "ext/date/lib/parse_date.re"
|
||||
#line 1796 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_sll i;
|
||||
int behavior = 0;
|
||||
@ -17291,7 +17292,7 @@ yy1179:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 17295 "<stdout>"
|
||||
#line 17296 "<stdout>"
|
||||
yy1180:
|
||||
YYDEBUG(1180, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
@ -17357,7 +17358,7 @@ yy1188:
|
||||
YYDEBUG(1188, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(1189, *YYCURSOR);
|
||||
#line 1254 "ext/date/lib/parse_date.re"
|
||||
#line 1255 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_sll i;
|
||||
int behavior = 0;
|
||||
@ -17378,7 +17379,7 @@ yy1188:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_WEEK_DAY_OF_MONTH;
|
||||
}
|
||||
#line 17382 "<stdout>"
|
||||
#line 17383 "<stdout>"
|
||||
yy1190:
|
||||
YYDEBUG(1190, *YYCURSOR);
|
||||
yyaccept = 26;
|
||||
@ -17518,7 +17519,7 @@ yy1205:
|
||||
}
|
||||
yy1206:
|
||||
YYDEBUG(1206, *YYCURSOR);
|
||||
#line 1771 "ext/date/lib/parse_date.re"
|
||||
#line 1772 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_sll i;
|
||||
int behavior = 0;
|
||||
@ -17541,7 +17542,7 @@ yy1206:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 17545 "<stdout>"
|
||||
#line 17546 "<stdout>"
|
||||
yy1207:
|
||||
YYDEBUG(1207, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -20490,7 +20491,7 @@ yy1387:
|
||||
}
|
||||
yy1388:
|
||||
YYDEBUG(1388, *YYCURSOR);
|
||||
#line 1231 "ext/date/lib/parse_date.re"
|
||||
#line 1232 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("backof | frontof");
|
||||
TIMELIB_INIT;
|
||||
@ -20512,7 +20513,7 @@ yy1388:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_LF_DAY_OF_MONTH;
|
||||
}
|
||||
#line 20516 "<stdout>"
|
||||
#line 20517 "<stdout>"
|
||||
yy1389:
|
||||
YYDEBUG(1389, *YYCURSOR);
|
||||
yyaccept = 28;
|
||||
@ -20811,7 +20812,7 @@ yy1410:
|
||||
YYDEBUG(1410, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
YYDEBUG(1411, *YYCURSOR);
|
||||
#line 1214 "ext/date/lib/parse_date.re"
|
||||
#line 1215 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("firstdayof | lastdayof");
|
||||
TIMELIB_INIT;
|
||||
@ -20827,7 +20828,7 @@ yy1410:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_LF_DAY_OF_MONTH;
|
||||
}
|
||||
#line 20831 "<stdout>"
|
||||
#line 20832 "<stdout>"
|
||||
yy1412:
|
||||
YYDEBUG(1412, *YYCURSOR);
|
||||
yyaccept = 1;
|
||||
@ -22349,7 +22350,7 @@ yy1483:
|
||||
if (yych <= '9') goto yy1483;
|
||||
yy1485:
|
||||
YYDEBUG(1485, *YYCURSOR);
|
||||
#line 1148 "ext/date/lib/parse_date.re"
|
||||
#line 1149 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_ull i;
|
||||
|
||||
@ -22374,7 +22375,7 @@ yy1485:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 22378 "<stdout>"
|
||||
#line 22379 "<stdout>"
|
||||
yy1486:
|
||||
YYDEBUG(1486, *YYCURSOR);
|
||||
++YYCURSOR;
|
||||
@ -22382,7 +22383,7 @@ yy1486:
|
||||
if (yych <= '9') goto yy1488;
|
||||
yy1487:
|
||||
YYDEBUG(1487, *YYCURSOR);
|
||||
#line 1174 "ext/date/lib/parse_date.re"
|
||||
#line 1175 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
timelib_sll i;
|
||||
timelib_ull us;
|
||||
@ -22421,7 +22422,7 @@ yy1487:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 22425 "<stdout>"
|
||||
#line 22426 "<stdout>"
|
||||
yy1488:
|
||||
YYDEBUG(1488, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -22890,7 +22891,7 @@ yy1523:
|
||||
++YYCURSOR;
|
||||
yy1524:
|
||||
YYDEBUG(1524, *YYCURSOR);
|
||||
#line 1136 "ext/date/lib/parse_date.re"
|
||||
#line 1137 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("tomorrow");
|
||||
TIMELIB_INIT;
|
||||
@ -22901,7 +22902,7 @@ yy1524:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 22905 "<stdout>"
|
||||
#line 22906 "<stdout>"
|
||||
yy1525:
|
||||
YYDEBUG(1525, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -22936,7 +22937,7 @@ yy1526:
|
||||
}
|
||||
yy1527:
|
||||
YYDEBUG(1527, *YYCURSOR);
|
||||
#line 1126 "ext/date/lib/parse_date.re"
|
||||
#line 1127 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("midnight | today");
|
||||
TIMELIB_INIT;
|
||||
@ -22945,7 +22946,7 @@ yy1527:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 22949 "<stdout>"
|
||||
#line 22950 "<stdout>"
|
||||
yy1528:
|
||||
YYDEBUG(1528, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -25040,7 +25041,7 @@ yy1611:
|
||||
}
|
||||
yy1612:
|
||||
YYDEBUG(1612, *YYCURSOR);
|
||||
#line 1105 "ext/date/lib/parse_date.re"
|
||||
#line 1106 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("now");
|
||||
TIMELIB_INIT;
|
||||
@ -25048,7 +25049,7 @@ yy1612:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 25052 "<stdout>"
|
||||
#line 25053 "<stdout>"
|
||||
yy1613:
|
||||
YYDEBUG(1613, *YYCURSOR);
|
||||
yych = *++YYCURSOR;
|
||||
@ -25187,7 +25188,7 @@ yy1619:
|
||||
}
|
||||
yy1620:
|
||||
YYDEBUG(1620, *YYCURSOR);
|
||||
#line 1114 "ext/date/lib/parse_date.re"
|
||||
#line 1115 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("noon");
|
||||
TIMELIB_INIT;
|
||||
@ -25198,7 +25199,7 @@ yy1620:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 25202 "<stdout>"
|
||||
#line 25203 "<stdout>"
|
||||
yy1621:
|
||||
YYDEBUG(1621, *YYCURSOR);
|
||||
yyaccept = 1;
|
||||
@ -25731,7 +25732,7 @@ yy1642:
|
||||
++YYCURSOR;
|
||||
yy1643:
|
||||
YYDEBUG(1643, *YYCURSOR);
|
||||
#line 1093 "ext/date/lib/parse_date.re"
|
||||
#line 1094 "ext/date/lib/parse_date.re"
|
||||
{
|
||||
DEBUG_OUTPUT("yesterday");
|
||||
TIMELIB_INIT;
|
||||
@ -25742,7 +25743,7 @@ yy1643:
|
||||
TIMELIB_DEINIT;
|
||||
return TIMELIB_RELATIVE;
|
||||
}
|
||||
#line 25746 "<stdout>"
|
||||
#line 25747 "<stdout>"
|
||||
yy1644:
|
||||
YYDEBUG(1644, *YYCURSOR);
|
||||
yyaccept = 1;
|
||||
@ -25915,7 +25916,7 @@ yy1649:
|
||||
goto yy1643;
|
||||
}
|
||||
}
|
||||
#line 1921 "ext/date/lib/parse_date.re"
|
||||
#line 1922 "ext/date/lib/parse_date.re"
|
||||
|
||||
}
|
||||
|
||||
|
@ -754,10 +754,11 @@ static timelib_long timelib_lookup_abbr(const char **ptr, int *dst, char **tz_ab
|
||||
timelib_long value = 0;
|
||||
const timelib_tz_lookup_table *tp;
|
||||
|
||||
/* Only include A-Z, a-z, /, _, and - in abbreviations/TZ IDs */
|
||||
/* Only include A-Z, a-z, 0-9, /, _, and - in abbreviations/TZ IDs */
|
||||
while (
|
||||
(**ptr >= 'A' && **ptr <= 'Z') ||
|
||||
(**ptr >= 'a' && **ptr <= 'z') ||
|
||||
(**ptr >= '0' && **ptr <= '9') ||
|
||||
**ptr == '/' || **ptr == '_' || **ptr == '-'
|
||||
) {
|
||||
++*ptr;
|
||||
|
Loading…
Reference in New Issue
Block a user