1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* parse.y (str_extend): make up "#$;" handling.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1934 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 2001-12-22 02:51:00 +00:00
parent 63b6b9c430
commit 0a45dee5a5
3 changed files with 7 additions and 0 deletions

View file

@ -1,3 +1,7 @@
Fri Dec 21 20:33:34 2001 K.Kosako <kosako@sofnec.co.jp>
* parse.y (str_extend): make up "#$;" handling.
Fri Dec 21 16:18:17 2001 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp>
* dln.h, ruby.h, util.h: enable prototypes in C++.

View file

@ -3931,6 +3931,7 @@ str_extend(list, term, paren)
case '!': case '@': case ',':
case '.': case '=': case ':':
case '<': case '>': case '\\':
case ';':
refetch:
tokadd(c);
goto fetch_id;

2
time.c
View file

@ -952,6 +952,7 @@ time_plus(time1, time2)
}
v = NUM2DBL(time2);
d = modf(v, &f);
sec = (time_t)f;
if (f != (double)sec || d >= 1.0 || d <= -1.0) {
rb_raise(rb_eRangeError, "time + %f out of Time range", v);
}
@ -998,6 +999,7 @@ time_minus(time1, time2)
}
v = NUM2DBL(time2);
d = modf(v, &f);
sec = (time_t)f;
if (f != (double)sec || d >= 1.0 || d <= -1.0) {
rb_raise(rb_eRangeError, "time - %f out of Time range", v);
}