com php-src: Rename timelib_get_zone to timelib_parse _zone and export.: ext/date/lib/parse_date.c ext/date/lib/parse_date.re ext/date/lib/timelib.h

From: Date: Sun, 09 Feb 2014 20:47:48 +0000
Subject: com php-src: Rename timelib_get_zone to timelib_parse _zone and export.: ext/date/lib/parse_date.c ext/date/lib/parse_date.re ext/date/lib/timelib.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-75943@lists.php.net to get a copy of this message
Commit: e196dce45a933c302fd028e9952b58f090ed444e Author: Derick Rethans <github@derickrethans.nl> Wed, 5 Feb 2014 20:59:10 -0500 Parents: 62404e767afbeadfaf6e0ceb8e53567238a75499 Branches: PHP-5.5 PHP-5..6 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=e196dce45a933c302fd028e9952b58f090ed444e Log: Rename timelib_get_zone to timelib_parse_zone and export. Changed paths: M ext/date/lib/parse_date.c M ext/date/lib/parse_date.re M ext/date/lib/timelib.h

diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index bb4c700..fd67d8b 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sat Jan 25 16:16:11 2014 */ +/* Generated by re2c 0.13.5 on Thu Feb 6 07:35:53 2014 */ #line 1 "ext/date/lib/parse_date.re" /* +----------------------------------------------------------------------+ @@ -751,7 +751,7 @@ static long timelib_lookup_zone(char **ptr, int *dst, char **tz_abbr, int *found return value; } -static long timelib_get_zone(char **ptr, int *dst, timelib_time *t, int *tz_not_found, const timelib_tzdb *tzdb, timelib_tz_get_wrapper tz_wrapper) +long timelib_parse_zone(char **ptr, int *dst, timelib_time *t, int *tz_not_found, const timelib_tzdb *tzdb, timelib_tz_get_wrapper tz_wrapper) { timelib_tzinfo *res; long retval = 0; @@ -1006,7 +1006,7 @@ yy4: DEBUG_OUTPUT("tzcorrection | tz"); TIMELIB_INIT; TIMELIB_HAVE_TZ(); - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -4468,7 +4468,7 @@ yy223: } if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -9798,7 +9798,7 @@ yy491: } if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -12073,7 +12073,7 @@ yy701: s->time->h = timelib_get_nr((char **) &ptr, 2); s->time->i = timelib_get_nr((char **) &ptr, 2); s->time->s = timelib_get_nr((char **) &ptr, 2); - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -13464,7 +13464,7 @@ yy843: if (*ptr == '.') { s->time->f = timelib_get_frac_nr((char **) &ptr, 9); if (*ptr) { /* timezone is optional */ - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -15813,7 +15813,7 @@ yy1076: s->time->s = timelib_get_nr((char **) &ptr, 2); if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -25047,7 +25047,7 @@ timelib_time *timelib_parse_from_format(char *format, char *string, int len, tim case 'O': /* timezone */ { int tz_not_found; - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_pbf_error(s, "The timezone could not be found in the database", string, begin); } diff --git a/ext/date/lib/parse_date.re b/ext/date/lib/parse_date.re index 0bb8fe6..e01e292 100644 --- a/ext/date/lib/parse_date.re +++ b/ext/date/lib/parse_date.re @@ -749,7 +749,7 @@ static long timelib_lookup_zone(char **ptr, int *dst, char **tz_abbr, int *found return value; } -static long timelib_get_zone(char **ptr, int *dst, timelib_time *t, int *tz_not_found, const timelib_tzdb *tzdb, timelib_tz_get_wrapper tz_wrapper) +long timelib_parse_zone(char **ptr, int *dst, timelib_time *t, int *tz_not_found, const timelib_tzdb *tzdb, timelib_tz_get_wrapper tz_wrapper) { timelib_tzinfo *res; long retval = 0; @@ -1161,7 +1161,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of } if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -1202,7 +1202,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of s->time->h = timelib_get_nr((char **) &ptr, 2); s->time->i = timelib_get_nr((char **) &ptr, 2); s->time->s = 0; - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, s->tzdb, tz_get_wrapper); break; case 1: s->time->y = timelib_get_nr((char **) &ptr, 4); @@ -1227,7 +1227,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of s->time->s = timelib_get_nr((char **) &ptr, 2); if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -1429,7 +1429,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of if (*ptr == '.') { s->time->f = timelib_get_frac_nr((char **) &ptr, 9); if (*ptr) { /* timezone is optional */ - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -1532,7 +1532,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of s->time->h = timelib_get_nr((char **) &ptr, 2); s->time->i = timelib_get_nr((char **) &ptr, 2); s->time->s = timelib_get_nr((char **) &ptr, 2); - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -1645,7 +1645,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of DEBUG_OUTPUT("tzcorrection | tz"); TIMELIB_INIT; TIMELIB_HAVE_TZ(); - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -1698,7 +1698,7 @@ weekdayof = (reltextnumber|reltexttext) space (dayfull|dayabbr) space 'of } if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_error(s, "The timezone could not be found in the database"); } @@ -2054,7 +2054,7 @@ timelib_time *timelib_parse_from_format(char *format, char *string, int len, tim case 'O': /* timezone */ { int tz_not_found; - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); + s->time->z = timelib_parse_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb, tz_get_wrapper); if (tz_not_found) { add_pbf_error(s, "The timezone could not be found in the database", string, begin); } diff --git a/ext/date/lib/timelib.h b/ext/date/lib/timelib.h index 866eaf3..08484fb 100644 --- a/ext/date/lib/timelib.h +++ b/ext/date/lib/timelib.h @@ -105,6 +105,7 @@ timelib_sll timelib_get_current_offset(timelib_time *t); void timelib_dump_tzinfo(timelib_tzinfo *tz); const timelib_tzdb *timelib_builtin_db(void); const timelib_tzdb_index_entry *timelib_timezone_builtin_identifiers_list(int *count); +long timelib_parse_zone(char **ptr, int *dst, timelib_time *t, int *tz_not_found, const timelib_tzdb *tzdb, timelib_tz_get_wrapper tz_wrapper); /* From timelib.c */ timelib_tzinfo* timelib_tzinfo_ctor(char *name);
« previous php.cvs (#75943) next »