mirror of
https://github.com/ruby/ruby.git
synced 2025-09-15 16:44:01 +02:00
* eval.c (thgroup_add): no warning for terminated threads.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
169300a4f8
commit
e02b469de1
8 changed files with 88 additions and 26 deletions
6
string.c
6
string.c
|
@ -2557,7 +2557,11 @@ rb_str_split_m(argc, argv, str)
|
|||
if (rb_scan_args(argc, argv, "02", &spat, &limit) == 2) {
|
||||
lim = NUM2INT(limit);
|
||||
if (lim <= 0) limit = Qnil;
|
||||
else if (lim == 1) return rb_ary_new3(1, str);
|
||||
else if (lim == 1) {
|
||||
if (RSTRING(str)->len == 0)
|
||||
return rb_ary_new2(0);
|
||||
return rb_ary_new3(1, str);
|
||||
}
|
||||
i = 1;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue