diff options
author | Derick Rethans <derick@php.net> | 2005-06-15 07:23:27 +0000 |
---|---|---|
committer | Derick Rethans <derick@php.net> | 2005-06-15 07:23:27 +0000 |
commit | 952a2c8234601cc13c6805b420410f64d389e2dc (patch) | |
tree | bbb39bc6c7214351b05741fb9bdedc6d0ef0cefe /ext | |
parent | f858c193b665ce03e5d2da9a63a4b2f612c06cae (diff) | |
download | php-git-952a2c8234601cc13c6805b420410f64d389e2dc.tar.gz |
- Whitespace and regenerate the .c file with my re2c.
Diffstat (limited to 'ext')
-rw-r--r-- | ext/date/lib/datetime.h | 2 | ||||
-rw-r--r-- | ext/date/lib/parse_date.c | 86 | ||||
-rw-r--r-- | ext/date/lib/parse_date.re | 10 | ||||
-rw-r--r-- | ext/date/lib/resource/parse_date.re | 10 | ||||
-rw-r--r-- | ext/date/lib/timelib_structs.h | 32 | ||||
-rw-r--r-- | ext/date/php_date.c | 2 |
6 files changed, 71 insertions, 71 deletions
diff --git a/ext/date/lib/datetime.h b/ext/date/lib/datetime.h index 553a2d0941..3cc4f2d11b 100644 --- a/ext/date/lib/datetime.h +++ b/ext/date/lib/datetime.h @@ -44,7 +44,7 @@ void timelib_fill_holes(timelib_time *parsed, timelib_time *now, int options); void timelib_update_ts(timelib_time* time, timelib_tzinfo* tzi); /* From unixtime2tm.c */ -int timelib_apply_localtime(timelib_time *t, unsigned int localtime); +int timelib_apply_localtime(timelib_time *t, unsigned int localtime); void timelib_unixtime2gmt(timelib_time* tm, timelib_sll ts); void timelib_unixtime2local(timelib_time *tm, timelib_sll ts, timelib_tzinfo* tz); void timelib_set_timezone(timelib_time *t, timelib_tzinfo *tz); diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index 9cd5a8d754..a416c5a97f 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.9.7 on Wed Jun 15 02:15:30 2005 */ +/* Generated by re2c 0.9.7.dev on Wed Jun 15 09:20:28 2005 */ #line 1 "parse_date.re" /* +----------------------------------------------------------------------+ @@ -120,14 +120,14 @@ typedef unsigned char uchar; #include "timelib_structs.h" typedef struct timelib_elems { - unsigned int c; /* Number of elements */ - char **v; /* Values */ + unsigned int c; /* Number of elements */ + char **v; /* Values */ } timelib_elems; typedef struct Scanner { - int fd; - uchar *lim, *str, *ptr, *cur, *tok, *pos; - unsigned int line, len; + int fd; + uchar *lim, *str, *ptr, *cur, *tok, *pos; + unsigned int line, len; struct timelib_time *time; } Scanner; @@ -742,7 +742,7 @@ std: s->tok = cursor; s->len = 0; #line 844 "parse_date.re" -{ + static unsigned char yybm[] = { 0, 0, 0, 0, 0, 0, 0, 0, @@ -779,7 +779,7 @@ std: 0, 0, 0, 0, 0, 0, 0, 0, }; -#line 40 "<stdout>" +#line 783 "<stdout>" { YYCTYPE yych; unsigned int yyaccept; @@ -864,7 +864,7 @@ yy3: TIMELIB_DEINIT; return TIMELIB_TIMEZONE; } -#line 118 "<stdout>" +#line 861 "<stdout>" yy4: YYDEBUG(4, *YYCURSOR); yych = *++YYCURSOR; @@ -938,7 +938,7 @@ yy7: printf("unexpected character: #%d, %c\n", *s->tok, *s->tok); goto std; } -#line 184 "<stdout>" +#line 927 "<stdout>" yy8: YYDEBUG(8, *YYCURSOR); yyaccept = 0; @@ -1676,7 +1676,7 @@ yy44: { goto std; } -#line 843 "<stdout>" +#line 1586 "<stdout>" yy45: YYDEBUG(45, *YYCURSOR); ++YYCURSOR; @@ -1689,7 +1689,7 @@ yy46: s->pos = cursor; s->line++; goto std; } -#line 852 "<stdout>" +#line 1595 "<stdout>" yy47: YYDEBUG(47, *YYCURSOR); yych = *++YYCURSOR; @@ -2057,7 +2057,7 @@ yy81: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 1149 "<stdout>" +#line 1892 "<stdout>" yy82: YYDEBUG(82, *YYCURSOR); ++YYCURSOR; @@ -2684,7 +2684,7 @@ yy148: { goto std; } -#line 1642 "<stdout>" +#line 2385 "<stdout>" yy149: YYDEBUG(149, *YYCURSOR); yych = *++YYCURSOR; @@ -2741,7 +2741,7 @@ yy155: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 1685 "<stdout>" +#line 2428 "<stdout>" yy156: YYDEBUG(156, *YYCURSOR); yyaccept = 1; @@ -3140,7 +3140,7 @@ yy188: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 2016 "<stdout>" +#line 2759 "<stdout>" yy189: YYDEBUG(189, *YYCURSOR); ++YYCURSOR; @@ -5297,7 +5297,7 @@ yy386: TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 3773 "<stdout>" +#line 4516 "<stdout>" yy387: YYDEBUG(387, *YYCURSOR); yych = *++YYCURSOR; @@ -5378,7 +5378,7 @@ yy397: TIMELIB_DEINIT; return TIMELIB_DATE_NO_DAY; } -#line 3832 "<stdout>" +#line 4575 "<stdout>" yy398: YYDEBUG(398, *YYCURSOR); yych = *++YYCURSOR; @@ -5432,7 +5432,7 @@ yy404: TIMELIB_DEINIT; return TIMELIB_PG_TEXT; } -#line 3872 "<stdout>" +#line 4615 "<stdout>" yy405: YYDEBUG(405, *YYCURSOR); yych = *++YYCURSOR; @@ -5592,7 +5592,7 @@ yy423: TIMELIB_DEINIT; return TIMELIB_SHORTDATE_WITH_TIME; } -#line 3994 "<stdout>" +#line 4737 "<stdout>" yy424: YYDEBUG(424, *YYCURSOR); yyaccept = 7; @@ -7268,7 +7268,7 @@ yy559: TIMELIB_DEINIT; return TIMELIB_AGO; } -#line 5398 "<stdout>" +#line 6141 "<stdout>" yy560: YYDEBUG(560, *YYCURSOR); yyaccept = 1; @@ -8923,7 +8923,7 @@ yy669: TIMELIB_DEINIT; return TIMELIB_TIME24_WITH_ZONE; } -#line 6829 "<stdout>" +#line 7572 "<stdout>" yy670: YYDEBUG(670, *YYCURSOR); yyaccept = 10; @@ -9064,7 +9064,7 @@ yy684: TIMELIB_DEINIT; return TIMELIB_TIME12; } -#line 6940 "<stdout>" +#line 7683 "<stdout>" yy685: YYDEBUG(685, *YYCURSOR); yych = *++YYCURSOR; @@ -9185,7 +9185,7 @@ yy697: TIMELIB_DEINIT; return TIMELIB_DATE_FULL; } -#line 7035 "<stdout>" +#line 7778 "<stdout>" yy698: YYDEBUG(698, *YYCURSOR); yych = *++YYCURSOR; @@ -9563,7 +9563,7 @@ yy756: TIMELIB_DEINIT; return TIMELIB_DATE_FULL_POINTED; } -#line 7295 "<stdout>" +#line 8038 "<stdout>" yy757: YYDEBUG(757, *YYCURSOR); yych = *++YYCURSOR; @@ -9946,7 +9946,7 @@ yy801: TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 7588 "<stdout>" +#line 8331 "<stdout>" yy802: YYDEBUG(802, *YYCURSOR); yych = *++YYCURSOR; @@ -9981,7 +9981,7 @@ yy805: TIMELIB_DEINIT; return TIMELIB_AMERICAN; } -#line 7615 "<stdout>" +#line 8358 "<stdout>" yy806: YYDEBUG(806, *YYCURSOR); yyaccept = 11; @@ -10218,7 +10218,7 @@ yy838: TIMELIB_DEINIT; return TIMELIB_CLF; } -#line 7786 "<stdout>" +#line 8529 "<stdout>" yy839: YYDEBUG(839, *YYCURSOR); yyaccept = 12; @@ -10541,7 +10541,7 @@ yy878: TIMELIB_DEINIT; return TIMELIB_PG_TEXT; } -#line 8028 "<stdout>" +#line 8771 "<stdout>" yy879: YYDEBUG(879, *YYCURSOR); yych = *++YYCURSOR; @@ -10798,7 +10798,7 @@ yy898: TIMELIB_DEINIT; return TIMELIB_DATE_NO_DAY; } -#line 8241 "<stdout>" +#line 8984 "<stdout>" yy899: YYDEBUG(899, *YYCURSOR); yych = *++YYCURSOR; @@ -10974,7 +10974,7 @@ yy919: TIMELIB_DEINIT; return TIMELIB_ISO_WEEK; } -#line 8375 "<stdout>" +#line 9118 "<stdout>" yy920: YYDEBUG(920, *YYCURSOR); yych = *++YYCURSOR; @@ -11018,7 +11018,7 @@ yy923: TIMELIB_DEINIT; return TIMELIB_PG_YEARDAY; } -#line 8411 "<stdout>" +#line 9154 "<stdout>" yy924: YYDEBUG(924, *YYCURSOR); yych = *++YYCURSOR; @@ -11104,7 +11104,7 @@ yy930: TIMELIB_DEINIT; return TIMELIB_DATE_NOCOLON; } -#line 8483 "<stdout>" +#line 9226 "<stdout>" yy931: YYDEBUG(931, *YYCURSOR); yych = *++YYCURSOR; @@ -11190,7 +11190,7 @@ yy941: TIMELIB_DEINIT; return TIMELIB_XMLRPC_SOAP; } -#line 8547 "<stdout>" +#line 9290 "<stdout>" yy942: YYDEBUG(942, *YYCURSOR); yych = *++YYCURSOR; @@ -11881,7 +11881,7 @@ yy1035: TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 9050 "<stdout>" +#line 9793 "<stdout>" yy1036: YYDEBUG(1036, *YYCURSOR); yych = *++YYCURSOR; @@ -12685,7 +12685,7 @@ yy1116: TIMELIB_DEINIT; return TIMELIB_GNU_NOCOLON; } -#line 9688 "<stdout>" +#line 10431 "<stdout>" yy1117: YYDEBUG(1117, *YYCURSOR); yych = *++YYCURSOR; @@ -12773,7 +12773,7 @@ yy1124: TIMELIB_DEINIT; return TIMELIB_ISO_NOCOLON; } -#line 9760 "<stdout>" +#line 10503 "<stdout>" yy1125: YYDEBUG(1125, *YYCURSOR); yyaccept = 19; @@ -12973,7 +12973,7 @@ yy1140: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 9926 "<stdout>" +#line 10669 "<stdout>" yy1141: YYDEBUG(1141, *YYCURSOR); yych = *++YYCURSOR; @@ -13032,7 +13032,7 @@ yy1149: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 9967 "<stdout>" +#line 10710 "<stdout>" yy1150: YYDEBUG(1150, *YYCURSOR); yych = *++YYCURSOR; @@ -13058,7 +13058,7 @@ yy1152: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 9987 "<stdout>" +#line 10730 "<stdout>" yy1153: YYDEBUG(1153, *YYCURSOR); yych = *++YYCURSOR; @@ -13089,7 +13089,7 @@ yy1155: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 10012 "<stdout>" +#line 10755 "<stdout>" yy1156: YYDEBUG(1156, *YYCURSOR); yych = *++YYCURSOR; @@ -13147,10 +13147,10 @@ yy1164: TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 10052 "<stdout>" +#line 10795 "<stdout>" } #line 1326 "parse_date.re" -} + } #define YYMAXFILL 25 diff --git a/ext/date/lib/parse_date.re b/ext/date/lib/parse_date.re index 93de7af8d1..3b29682bd8 100644 --- a/ext/date/lib/parse_date.re +++ b/ext/date/lib/parse_date.re @@ -118,14 +118,14 @@ typedef unsigned char uchar; #include "timelib_structs.h" typedef struct timelib_elems { - unsigned int c; /* Number of elements */ - char **v; /* Values */ + unsigned int c; /* Number of elements */ + char **v; /* Values */ } timelib_elems; typedef struct Scanner { - int fd; - uchar *lim, *str, *ptr, *cur, *tok, *pos; - unsigned int line, len; + int fd; + uchar *lim, *str, *ptr, *cur, *tok, *pos; + unsigned int line, len; struct timelib_time *time; } Scanner; diff --git a/ext/date/lib/resource/parse_date.re b/ext/date/lib/resource/parse_date.re index 93de7af8d1..3b29682bd8 100644 --- a/ext/date/lib/resource/parse_date.re +++ b/ext/date/lib/resource/parse_date.re @@ -118,14 +118,14 @@ typedef unsigned char uchar; #include "timelib_structs.h" typedef struct timelib_elems { - unsigned int c; /* Number of elements */ - char **v; /* Values */ + unsigned int c; /* Number of elements */ + char **v; /* Values */ } timelib_elems; typedef struct Scanner { - int fd; - uchar *lim, *str, *ptr, *cur, *tok, *pos; - unsigned int line, len; + int fd; + uchar *lim, *str, *ptr, *cur, *tok, *pos; + unsigned int line, len; struct timelib_time *time; } Scanner; diff --git a/ext/date/lib/timelib_structs.h b/ext/date/lib/timelib_structs.h index eb49ad487b..f3bf325091 100644 --- a/ext/date/lib/timelib_structs.h +++ b/ext/date/lib/timelib_structs.h @@ -86,32 +86,32 @@ typedef struct timelib_rel_time { } timelib_rel_time; typedef struct timelib_time_offset { - int32_t offset; + int32_t offset; unsigned int leap_secs; unsigned int is_dst; - char *abbr; + char *abbr; } timelib_time_offset; typedef struct timelib_time { - timelib_sll y, m, d; /* Year, Month, Day */ - timelib_sll h, i, s; /* Hour, mInute, Second */ - float f; /* Fraction */ - int z; /* GMT offset in minutes */ - char *tz_abbr; /* Timezone abbreviation (display only) */ - timelib_tzinfo *tz_info; /* Timezone structure */ - unsigned int dst; /* Flag if we were parsing a DST zone */ + timelib_sll y, m, d; /* Year, Month, Day */ + timelib_sll h, i, s; /* Hour, mInute, Second */ + float f; /* Fraction */ + int z; /* GMT offset in minutes */ + char *tz_abbr; /* Timezone abbreviation (display only) */ + timelib_tzinfo *tz_info; /* Timezone structure */ + unsigned int dst; /* Flag if we were parsing a DST zone */ timelib_rel_time relative; - timelib_sll sse; /* Seconds since epoch */ + timelib_sll sse; /* Seconds since epoch */ unsigned int have_time, have_date, have_zone, have_relative, have_weekday_relative, have_weeknr_day; - unsigned int sse_uptodate; /* !0 if the sse member is up to date with the date/time members */ - unsigned int tim_uptodate; /* !0 if the date/time members are up to date with the sse member */ - unsigned int is_localtime; /* 1 if the current struct represents localtime, 0 if it is in GMT */ - unsigned int zone_type; /* 1 time offset, - * 3 TimeZone identifier, - * 2 TimeZone abbreviation */ + unsigned int sse_uptodate; /* !0 if the sse member is up to date with the date/time members */ + unsigned int tim_uptodate; /* !0 if the date/time members are up to date with the sse member */ + unsigned int is_localtime; /* 1 if the current struct represents localtime, 0 if it is in GMT */ + unsigned int zone_type; /* 1 time offset, + * 3 TimeZone identifier, + * 2 TimeZone abbreviation */ } timelib_time; #define TIMELIB_ZONETYPE_OFFSET 1 diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 40ff4a9a03..fae5f5556d 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -132,7 +132,7 @@ PHP_FUNCTION(strtotime) now = timelib_time_ctor(); timelib_unixtime2local(now, (timelib_sll) time(NULL), tzi); } else { - timelib_tzinfo_ctor(tzi); + timelib_tzinfo_dtor(tzi); RETURN_FALSE; } |