зеркало из https://github.com/github/ruby.git
* array.c (rb_ary_aset): fixed arguments evaluation order.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21780 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
5225998612
Коммит
c330fb421e
|
@ -1,3 +1,7 @@
|
||||||
|
Mon Jan 26 16:00:40 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* array.c (rb_ary_aset): fixed arguments evaluation order.
|
||||||
|
|
||||||
Mon Jan 26 15:49:42 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Mon Jan 26 15:49:42 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* lib/pathname.rb (chop_basename, prepend_prefix): use o option.
|
* lib/pathname.rb (chop_basename, prepend_prefix): use o option.
|
||||||
|
|
4
array.c
4
array.c
|
@ -1270,7 +1270,9 @@ rb_ary_aset(int argc, VALUE *argv, VALUE ary)
|
||||||
long offset, beg, len;
|
long offset, beg, len;
|
||||||
|
|
||||||
if (argc == 3) {
|
if (argc == 3) {
|
||||||
rb_ary_splice(ary, NUM2LONG(argv[0]), NUM2LONG(argv[1]), argv[2]);
|
beg = NUM2LONG(argv[0]);
|
||||||
|
len = NUM2LONG(argv[1]);
|
||||||
|
rb_ary_splice(ary, beg, len, argv[2]);
|
||||||
return argv[2];
|
return argv[2];
|
||||||
}
|
}
|
||||||
if (argc != 2) {
|
if (argc != 2) {
|
||||||
|
|
Загрузка…
Ссылка в новой задаче