10 #define sizeof_array(o) (sizeof o / sizeof o[0]) 12 #define f_negate(x) rb_funcall(x, rb_intern("-@"), 0) 13 #define f_add(x,y) rb_funcall(x, '+', 1, y) 14 #define f_sub(x,y) rb_funcall(x, '-', 1, y) 15 #define f_mul(x,y) rb_funcall(x, '*', 1, y) 16 #define f_div(x,y) rb_funcall(x, '/', 1, y) 17 #define f_idiv(x,y) rb_funcall(x, rb_intern("div"), 1, y) 18 #define f_mod(x,y) rb_funcall(x, '%', 1, y) 19 #define f_expt(x,y) rb_funcall(x, rb_intern("**"), 1, y) 21 #define f_lt_p(x,y) rb_funcall(x, '<', 1, y) 22 #define f_gt_p(x,y) rb_funcall(x, '>', 1, y) 23 #define f_le_p(x,y) rb_funcall(x, rb_intern("<="), 1, y) 24 #define f_ge_p(x,y) rb_funcall(x, rb_intern(">="), 1, y) 26 #define f_to_s(x) rb_funcall(x, rb_intern("to_s"), 0) 28 #define f_match(r,s) rb_funcall(r, rb_intern("match"), 1, s) 29 #define f_aref(o,i) rb_funcall(o, rb_intern("[]"), 1, i) 30 #define f_aref2(o,i,j) rb_funcall(o, rb_intern("[]"), 2, i, j) 31 #define f_begin(o,i) rb_funcall(o, rb_intern("begin"), 1, i) 32 #define f_end(o,i) rb_funcall(o, rb_intern("end"), 1, i) 33 #define f_aset(o,i,v) rb_funcall(o, rb_intern("[]="), 2, i, v) 34 #define f_aset2(o,i,j,v) rb_funcall(o, rb_intern("[]="), 3, i, j, v) 35 #define f_sub_bang(s,r,x) rb_funcall(s, rb_intern("sub!"), 2, r, x) 36 #define f_gsub_bang(s,r,x) rb_funcall(s, rb_intern("gsub!"), 2, r, x) 38 #define set_hash(k,v) rb_hash_aset(hash, ID2SYM(rb_intern(k)), v) 39 #define ref_hash(k) rb_hash_aref(hash, ID2SYM(rb_intern(k))) 40 #define del_hash(k) rb_hash_delete(hash, ID2SYM(rb_intern(k))) 42 #define cstr2num(s) rb_cstr_to_inum(s, 10, 0) 43 #define str2num(s) rb_str_to_inum(s, 10, 0) 46 "sun",
"mon",
"tue",
"wed",
51 "jan",
"feb",
"mar",
"apr",
"may",
"jun",
52 "jul",
"aug",
"sep",
"oct",
"nov",
"dec" 55 #define issign(c) ((c) == '-' || (c) == '+') 56 #define asp_string() rb_str_new(" ", 1) 88 const char *s, *
bp, *ep;
92 while (!
issign(*s) && !isdigit(*s))
97 l = strspn(s,
"0123456789");
135 const char *s, *
bp, *ep;
141 while (!
issign(*s) && !isdigit(*s))
150 l = strspn(s,
"0123456789");
168 const char *s, *
bp, *ep;
176 l = strspn(s,
"0123456789");
190 const char *s, *
bp, *ep;
198 l = strspn(s,
"0123456789");
215 #define DAYS "sunday|monday|tuesday|wednesday|thursday|friday|saturday" 216 #define MONTHS "january|february|march|april|may|june|july|august|september|october|november|december" 217 #define ABBR_DAYS "sun|mon|tue|wed|thu|fri|sat" 218 #define ABBR_MONTHS "jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec" 230 #define REGCOMP(pat,opt) \ 233 pat = regcomp(pat##_source, sizeof pat##_source - 1, opt); \ 236 #define REGCOMP_0(pat) REGCOMP(pat, 0) 237 #define REGCOMP_I(pat) REGCOMP(pat, ONIG_OPTION_IGNORECASE) 239 #define MATCH(s,p,c) \ 241 return match(s, p, hash, c); \ 259 #define SUBS(s,p,c) \ 261 return subs(s, p, hash, c); \ 292 {
"ut", 0*3600}, {
"gmt", 0*3600}, {
"est", -5*3600}, {
"edt", -4*3600},
293 {
"cst", -6*3600}, {
"cdt", -5*3600}, {
"mst", -7*3600}, {
"mdt", -6*3600},
294 {
"pst", -8*3600}, {
"pdt", -7*3600},
295 {
"a", 1*3600}, {
"b", 2*3600}, {
"c", 3*3600}, {
"d", 4*3600},
296 {
"e", 5*3600}, {
"f", 6*3600}, {
"g", 7*3600}, {
"h", 8*3600},
297 {
"i", 9*3600}, {
"k", 10*3600}, {
"l", 11*3600}, {
"m", 12*3600},
298 {
"n", -1*3600}, {
"o", -2*3600}, {
"p", -3*3600}, {
"q", -4*3600},
299 {
"r", -5*3600}, {
"s", -6*3600}, {
"t", -7*3600}, {
"u", -8*3600},
300 {
"v", -9*3600}, {
"w", -10*3600}, {
"x", -11*3600}, {
"y", -12*3600},
303 {
"utc", 0*3600}, {
"wet", 0*3600},
304 {
"at", -2*3600}, {
"brst",-2*3600}, {
"ndt", -(2*3600+1800)},
305 {
"art", -3*3600}, {
"adt", -3*3600}, {
"brt", -3*3600}, {
"clst",-3*3600},
306 {
"nst", -(3*3600+1800)},
307 {
"ast", -4*3600}, {
"clt", -4*3600},
308 {
"akdt",-8*3600}, {
"ydt", -8*3600},
309 {
"akst",-9*3600}, {
"hadt",-9*3600}, {
"hdt", -9*3600}, {
"yst", -9*3600},
310 {
"ahst",-10*3600},{
"cat",-10*3600}, {
"hast",-10*3600},{
"hst",-10*3600},
313 {
"bst", 1*3600}, {
"cet", 1*3600}, {
"fwt", 1*3600}, {
"met", 1*3600},
314 {
"mewt", 1*3600}, {
"mez", 1*3600}, {
"swt", 1*3600}, {
"wat", 1*3600},
316 {
"cest", 2*3600}, {
"eet", 2*3600}, {
"fst", 2*3600}, {
"mest", 2*3600},
317 {
"mesz", 2*3600}, {
"sast", 2*3600}, {
"sst", 2*3600},
318 {
"bt", 3*3600}, {
"eat", 3*3600}, {
"eest", 3*3600}, {
"msk", 3*3600},
319 {
"msd", 4*3600}, {
"zp4", 4*3600},
320 {
"zp5", 5*3600}, {
"ist", (5*3600+1800)},
323 {
"cct", 8*3600}, {
"sgt", 8*3600}, {
"wadt", 8*3600},
324 {
"jst", 9*3600}, {
"kst", 9*3600},
325 {
"east",10*3600}, {
"gst", 10*3600},
327 {
"idle",12*3600}, {
"nzst",12*3600}, {
"nzt", 12*3600},
330 {
"afghanistan", 16200}, {
"alaskan", -32400},
331 {
"arab", 10800}, {
"arabian", 14400},
332 {
"arabic", 10800}, {
"atlantic", -14400},
333 {
"aus central", 34200}, {
"aus eastern", 36000},
334 {
"azores", -3600}, {
"canada central", -21600},
335 {
"cape verde", -3600}, {
"caucasus", 14400},
336 {
"cen. australia", 34200}, {
"central america", -21600},
337 {
"central asia", 21600}, {
"central europe", 3600},
338 {
"central european", 3600}, {
"central pacific", 39600},
339 {
"central", -21600}, {
"china", 28800},
340 {
"dateline", -43200}, {
"e. africa", 10800},
341 {
"e. australia", 36000}, {
"e. europe", 7200},
342 {
"e. south america", -10800}, {
"eastern", -18000},
343 {
"egypt", 7200}, {
"ekaterinburg", 18000},
344 {
"fiji", 43200}, {
"fle", 7200},
345 {
"greenland", -10800}, {
"greenwich", 0},
346 {
"gtb", 7200}, {
"hawaiian", -36000},
347 {
"india", 19800}, {
"iran", 12600},
348 {
"jerusalem", 7200}, {
"korea", 32400},
349 {
"mexico", -21600}, {
"mid-atlantic", -7200},
350 {
"mountain", -25200}, {
"myanmar", 23400},
351 {
"n. central asia", 21600}, {
"nepal", 20700},
352 {
"new zealand", 43200}, {
"newfoundland", -12600},
353 {
"north asia east", 28800}, {
"north asia", 25200},
354 {
"pacific sa", -14400}, {
"pacific", -28800},
355 {
"romance", 3600}, {
"russian", 10800},
356 {
"sa eastern", -10800}, {
"sa pacific", -18000},
357 {
"sa western", -14400}, {
"samoa", -39600},
358 {
"se asia", 25200}, {
"malay peninsula", 28800},
359 {
"south africa", 7200}, {
"sri lanka", 21600},
360 {
"taipei", 28800}, {
"tasmania", 36000},
361 {
"tokyo", 32400}, {
"tonga", 46800},
362 {
"us eastern", -18000}, {
"us mountain", -25200},
363 {
"vladivostok", 36000}, {
"w. australia", 28800},
364 {
"w. central africa", 3600}, {
"w. europe", 3600},
365 {
"west asia", 18000}, {
"west pacific", 36000},
383 for (
i = 0;
i < l;
i++) {
384 if (isspace(s[
i]) || s[
i] ==
'\0') {
391 *d++ = tolower(s[
i]);
404 #define STD " standard time" 405 #define DST " daylight time" 415 if (sl >= 0 && strcmp(ss,
STD) == 0) {
418 else if (dl >= 0 && strcmp(ds,
DST) == 0) {
432 if (dl >= 0 && strcmp(ds,
DST) == 0) {
469 if (strncmp(s,
"gmt", 3) == 0 ||
470 strncmp(s,
"utc", 3) == 0)
500 b = strpbrk(a,
",.");
596 static const char pat_source[] =
"\\b(" ABBR_DAYS ")[^-\\d\\s]*";
649 static const char pat_source[] =
651 "(?:\\s*:?\\s*(\\d+)m?" 653 "\\s*:?\\s*(\\d+)(?:[,.](\\d+))?s?" 656 "(?:\\s*([ap])(?:m\\b|\\.m\\.))?";
682 static const char pat_source[] =
687 "\\s*:\\s*\\d+(?:[,.]\\d*)?" 690 "\\d+\\s*h(?:\\s*\\d+m?(?:\\s*\\d+s?)?)?" 694 "[ap](?:m\\b|\\.m\\.)" 697 "\\d+\\s*[ap](?:m\\b|\\.m\\.)" 702 "(?:gmt|utc?)?[-+]\\d+(?:[,.:]\\d+(?::\\d+)?)?" 704 "(?-i:[[:alpha:].\\s]+)(?:standard|daylight)\\stime\\b" 706 "(?-i:[[:alpha:]]+)(?:\\sdst)?\\b" 736 static const char pat_source[] =
737 "'?(\\d+)[^-\\d\\s]*" 742 "(c(?:e|\\.e\\.)|b(?:ce|\\.c\\.e\\.)|a(?:d|\\.d\\.)|b(?:c|\\.c\\.))?" 744 "('?-?\\d+(?:(?:st|nd|rd|th)\\b)?)" 749 SUBS(str, pat, parse_eu_cb);
773 static const char pat_source[] =
776 "('?\\d+)[^-\\d\\s']*" 779 "(c(?:e|\\.e\\.)|b(?:ce|\\.c\\.e\\.)|a(?:d|\\.d\\.)|b(?:c|\\.c\\.))?" 786 SUBS(str, pat, parse_us_cb);
805 static const char pat_source[] =
"('?[-+]?\\d+)-(\\d+)-('?-?\\d+)";
809 SUBS(str, pat, parse_iso_cb);
833 static const char pat_source[] =
834 "\\b(\\d{2}|\\d{4})?-?w(\\d{2})(?:-?(\\d))?\\b";
838 SUBS(str, pat, parse_iso21_cb);
854 static const char pat_source[] =
"-w-(\\d)\\b";
858 SUBS(str, pat, parse_iso22_cb);
879 static const char pat_source[] =
"--(\\d{2})?-(\\d{2})\\b";
883 SUBS(str, pat, parse_iso23_cb);
904 static const char pat_source[] =
"--(\\d{2})(\\d{2})?\\b";
908 SUBS(str, pat, parse_iso24_cb);
928 static const char pat0_source[] =
"[,.](\\d{2}|\\d{4})-\\d{3}\\b";
930 static const char pat_source[] =
"\\b(\\d{2}|\\d{4})-(\\d{3})\\b";
938 SUBS(str, pat, parse_iso25_cb);
954 static const char pat0_source[] =
"\\d-\\d{3}\\b";
956 static const char pat_source[] =
"\\b-(\\d{3})\\b";
964 SUBS(str, pat, parse_iso26_cb);
970 if (parse_iso21(str,
hash))
972 if (parse_iso22(str,
hash))
974 if (parse_iso23(str,
hash))
976 if (parse_iso24(str,
hash))
978 if (parse_iso25(str,
hash))
980 if (parse_iso26(str,
hash))
994 case 'M':
case 'm': e = 1867;
break;
995 case 'T':
case 't': e = 1911;
break;
996 case 'S':
case 's': e = 1925;
break;
997 case 'H':
case 'h': e = 1988;
break;
998 default: e = 0;
break;
1026 static const char pat_source[] =
"\\b([mtsh])(\\d+)\\.(\\d+)\\.(\\d+)";
1030 SUBS(str, pat, parse_jis_cb);
1051 static const char pat_source[] =
1057 SUBS(str, pat, parse_vms11_cb);
1078 static const char pat_source[] =
1080 "-('?-?\\d+)(?:-('?-?\\d+))?";
1084 SUBS(str, pat, parse_vms12_cb);
1090 if (parse_vms11(str,
hash))
1092 if (parse_vms12(str,
hash))
1116 static const char pat_source[] =
1117 "('?-?\\d+)/\\s*('?\\d+)(?:\\D\\s*('?-?\\d+))?";
1121 SUBS(str, pat, parse_sla_cb);
1140 static const char pat_source[] =
1141 "('?-?\\d+)\\.\\s*('?\\d+)\\.\\s*('?-?\\d+)";
1145 SUBS(str, pat, parse_dot_cb);
1161 static const char pat_source[] =
"'(\\d+)\\b";
1165 SUBS(str, pat, parse_year_cb);
1181 static const char pat_source[] =
"\\b(" ABBR_MONTHS ")\\S*";
1185 SUBS(str, pat, parse_mon_cb);
1201 static const char pat_source[] =
"(\\d+)(st|nd|rd|th)\\b";
1205 SUBS(str, pat, parse_mday_cb);
1209 n2i(
const char *s,
long f,
long w)
1216 for (
i = f;
i < e;
i++) {
1226 VALUE s1, s2, s3, s4, s5;
1227 const char *cs2, *cs3, *cs5;
1228 long l2, l3, l4, l5;
1263 int y = n2i(cs2, 0, 2);
1283 int y = n2i(cs2, l2-12, 2);
1289 int y = n2i(cs2, l2-14, 4);
1297 int y = n2i(cs2, 0, 4);
1327 int y = n2i(cs2, 0, 2);
1342 int y = n2i(cs2, 0, 4);
1401 memcpy(
buf, cs5, l5);
1429 static const char pat_source[] =
1430 "([-+]?)(\\d{2,14})" 1435 "(\\d{2,6})?(?:[,.](\\d*))?" 1444 "\\[[-+]?\\d[^\\]]*\\]" 1450 SUBS(str, pat, parse_ddd_cb);
1468 static const char pat_source[] =
1469 "\\b(bc\\b|bce\\b|b\\.c\\.|b\\.c\\.e\\.)";
1473 SUBS(str, pat, parse_bc_cb);
1502 static const char pat_source[] =
"\\A\\s*(\\d{1,2})\\s*\\z";
1506 SUBS(str, pat, parse_frag_cb);
1509 #define HAVE_ALPHA (1<<0) 1510 #define HAVE_DIGIT (1<<1) 1511 #define HAVE_DASH (1<<2) 1512 #define HAVE_DOT (1<<3) 1513 #define HAVE_SLASH (1<<4) 1516 check_class(
VALUE s)
1537 #define HAVE_ELEM_P(x) ((check_class(str) & (x)) == (x)) 1548 static const char pat_source[] =
"[^-+',./:@[:alnum:]\\[\\]]+";
1565 if (parse_eu(str,
hash))
1568 if (parse_us(str,
hash))
1571 if (parse_iso(str,
hash))
1574 if (parse_jis(str,
hash))
1577 if (parse_vms(str,
hash))
1580 if (parse_sla(str,
hash))
1583 if (parse_dot(str,
hash))
1586 if (parse_iso2(str,
hash))
1589 if (parse_year(str,
hash))
1592 if (parse_mon(str,
hash))
1595 if (parse_mday(str,
hash))
1598 if (parse_ddd(str,
hash))
1603 parse_bc(str,
hash);
1605 parse_frag(str,
hash);
1644 comp_year69(
VALUE y)
1652 comp_year50(
VALUE y)
1660 sec_fraction(
VALUE f)
1696 else if (!
NIL_P(s[5])) {
1705 else if (!
NIL_P(s[8])) {
1715 else if (!
NIL_P(s[9])) {
1718 if (!
NIL_P(s[10])) {
1724 if (!
NIL_P(s[13])) {
1725 set_hash(
"sec_fraction", sec_fraction(s[13]));
1727 if (!
NIL_P(s[14])) {
1738 static const char pat_source[] =
1739 "\\A\\s*(?:([-+]?\\d{2,}|-)-(\\d{2})?-(\\d{2})|" 1740 "([-+]?\\d{2,})?-(\\d{3})|" 1741 "(\\d{4}|\\d{2})?-w(\\d{2})-(\\d)|" 1744 "(\\d{2}):(\\d{2})(?::(\\d{2})(?:[,.](\\d+))?)?" 1745 "(z|[-+]\\d{2}(?::?\\d{2})?)?)?\\s*\\z";
1749 MATCH(str, pat, iso8601_ext_datetime_cb);
1782 else if (!
NIL_P(s[5])) {
1789 else if (!
NIL_P(s[6])) {
1792 else if (!
NIL_P(s[9])) {
1800 else if (!
NIL_P(s[11])) {
1804 else if (!
NIL_P(s[12])) {
1807 if (!
NIL_P(s[13])) {
1813 if (!
NIL_P(s[16])) {
1814 set_hash(
"sec_fraction", sec_fraction(s[16]));
1816 if (!
NIL_P(s[17])) {
1827 static const char pat_source[] =
1828 "\\A\\s*(?:([-+]?(?:\\d{4}|\\d{2})|--)(\\d{2}|-)(\\d{2})|" 1829 "([-+]?(?:\\d{4}|\\d{2}))(\\d{3})|" 1831 "(\\d{4}|\\d{2})w(\\d{2})(\\d)|" 1835 "(\\d{2})(\\d{2})(?:(\\d{2})(?:[,.](\\d+))?)?" 1836 "(z|[-+]\\d{2}(?:\\d{2})?)?)?\\s*\\z";
1840 MATCH(str, pat, iso8601_bas_datetime_cb);
1863 set_hash(
"sec_fraction", sec_fraction(s[4]));
1872 #define iso8601_bas_time_cb iso8601_ext_time_cb 1877 static const char pat_source[] =
1878 "\\A\\s*(?:(\\d{2}):(\\d{2})(?::(\\d{2})(?:[,.](\\d+))?)?" 1879 "(z|[-+]\\d{2}(:?\\d{2})?)?)?\\s*\\z";
1883 MATCH(str, pat, iso8601_ext_time_cb);
1889 static const char pat_source[] =
1890 "\\A\\s*(?:(\\d{2})(\\d{2})(?:(\\d{2})(?:[,.](\\d+))?)?" 1891 "(z|[-+]\\d{2}(\\d{2})?)?)?\\s*\\z";
1908 if (iso8601_ext_datetime(str,
hash))
1910 if (iso8601_bas_datetime(str,
hash))
1912 if (iso8601_ext_time(str,
hash))
1914 if (iso8601_bas_time(str,
hash))
1947 set_hash(
"sec_fraction", sec_fraction(s[7]));
1955 static const char pat_source[] =
1956 "\\A\\s*(-?\\d{4})-(\\d{2})-(\\d{2})" 1958 "(\\d{2}):(\\d{2}):(\\d{2})(?:\\.(\\d+))?" 1959 "(z|[-+]\\d{2}:\\d{2})\\s*\\z";
1963 MATCH(str, pat, rfc3339_cb);
2007 set_hash(
"sec_fraction", sec_fraction(s[7]));
2019 static const char pat_source[] =
2020 "\\A\\s*(-?\\d{4,})(?:-(\\d{2})(?:-(\\d{2}))?)?" 2022 "(\\d{2}):(\\d{2}):(\\d{2})(?:\\.(\\d+))?)?" 2023 "(z|[-+]\\d{2}:\\d{2})?\\s*\\z";
2027 MATCH(str, pat, xmlschema_datetime_cb);
2050 set_hash(
"sec_fraction", sec_fraction(s[4]));
2062 static const char pat_source[] =
2063 "\\A\\s*(\\d{2}):(\\d{2}):(\\d{2})(?:\\.(\\d+))?" 2064 "(z|[-+]\\d{2}:\\d{2})?\\s*\\z";
2068 MATCH(str, pat, xmlschema_time_cb);
2103 static const char pat_source[] =
2104 "\\A\\s*(?:--(\\d{2})(?:-(\\d{2}))?|---(\\d{2}))" 2105 "(z|[-+]\\d{2}:\\d{2})?\\s*\\z";
2109 MATCH(str, pat, xmlschema_trunc_cb);
2122 if (xmlschema_datetime(str,
hash))
2124 if (xmlschema_time(str,
hash))
2126 if (xmlschema_trunc(str,
hash))
2172 static const char pat_source[] =
2177 "(\\d{2}):(\\d{2})(?::(\\d{2}))?\\s*" 2178 "([-+]\\d{4}|ut|gmt|e[sd]t|c[sd]t|m[sd]t|p[sd]t|[a-ik-z])\\s*\\z";
2182 MATCH(str, pat, rfc2822_cb);
2230 static const char pat_source[] =
2235 "(\\d{2}):(\\d{2}):(\\d{2})\\s+" 2240 MATCH(str, pat, httpdate_type1_cb);
2277 static const char pat_source[] =
2278 "\\A\\s*(" DAYS ")\\s*,\\s+" 2282 "(\\d{2}):(\\d{2}):(\\d{2})\\s+" 2287 MATCH(str, pat, httpdate_type2_cb);
2319 static const char pat_source[] =
2323 "(\\d{2}):(\\d{2}):(\\d{2})\\s+" 2328 MATCH(str, pat, httpdate_type3_cb);
2341 if (httpdate_type1(str,
hash))
2343 if (httpdate_type2(str,
hash))
2345 if (httpdate_type3(str,
hash))
2382 set_hash(
"sec_fraction", sec_fraction(s[8]));
2394 static const char pat_source[] =
2395 "\\A\\s*([mtsh])?(\\d{2})\\.(\\d{2})\\.(\\d{2})" 2397 "(?:(\\d{2}):(\\d{2})(?::(\\d{2})(?:[,.](\\d*))?)?" 2398 "(z|[-+]\\d{2}(?::?\\d{2})?)?)?)?\\s*\\z";
2402 MATCH(str, pat, jisx0301_cb);
2414 if (jisx0301(str,
hash))
#define RSTRING_LEN(string)
static long NUM2LONG(VALUE x)
static int parse_time2_cb(VALUE m, VALUE hash)
#define rb_rational_new2(x, y)
size_t strlen(const char *)
void rb_backref_set(VALUE)
static int parse_day(VALUE str, VALUE hash)
static const char * abbr_months[]
static void s3e(VALUE hash, VALUE y, VALUE m, VALUE d, int bc)
static int parse_day_cb(VALUE m, VALUE hash)
#define RSTRING_PTR(string)
VALUE rb_backref_get(void)
VALUE date__rfc3339(VALUE)
static VALUE regcomp(const char *source, long len, int opt)
static int min(int a, int b)
VALUE date__jisx0301(VALUE)
static int parse_time(VALUE str, VALUE hash)
static int day_num(VALUE s)
VALUE rb_hash_aset(VALUE hash, VALUE key, VALUE val)
VALUE date_zone_to_diff(VALUE str)
static int parse_time_cb(VALUE m, VALUE hash)
#define ALLOCA_N(type, n)
void rb_gc_register_mark_object(VALUE obj)
VALUE date__parse(VALUE str, VALUE comp)
VALUE rb_reg_new(const char *, long, int)
static int mon_num(VALUE s)
#define RB_GC_GUARD(object)
VALUE date__iso8601(VALUE)
unsigned char buf[MIME_BUF_SIZE]
char * strchr(char *, char)
static struct zone zones_source[]
register unsigned int len
void rb_match_busy(VALUE)
#define iso8601_bas_time_cb
static const char * abbr_days[]
#define f_gsub_bang(s, r, x)
#define f_aset2(o, i, j, v)
VALUE date__httpdate(VALUE)
static int subs(VALUE str, VALUE pat, VALUE hash, int(*cb)(VALUE, VALUE))
static unsigned int hash(const char *str, unsigned int len)
VALUE date__rfc2822(VALUE)
VALUE date__xmlschema(VALUE)
static int match(VALUE str, VALUE pat, VALUE hash, int(*cb)(VALUE, VALUE))
VALUE rb_str_new2(const char *)
VALUE rb_reg_nth_match(int, VALUE)
VALUE rb_str_new(const char *, long)