зеркало из https://github.com/github/ruby.git
* array.c (sort_2): get rid of yet another bcc's bug.
fixed: [ruby-core:05152] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
5a33a2c74a
Коммит
11921b1861
|
@ -1,3 +1,8 @@
|
|||
Tue Jul 5 23:23:09 2005 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* array.c (sort_2): get rid of yet another bcc's bug.
|
||||
fixed: [ruby-core:05152]
|
||||
|
||||
Tue Jul 5 15:15:10 2005 Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp>
|
||||
|
||||
* ext/tk/tkutil.c: fix typo.
|
||||
|
|
4
array.c
4
array.c
|
@ -1630,8 +1630,8 @@ sort_2(ap, bp, data)
|
|||
if ((long)a < (long)b) return -1;
|
||||
return 0;
|
||||
}
|
||||
if (TYPE(a) == T_STRING && TYPE(b) == T_STRING) {
|
||||
return rb_str_cmp(a, b);
|
||||
if (TYPE(a) == T_STRING) {
|
||||
if (TYPE(b) == T_STRING) return rb_str_cmp(a, b);
|
||||
}
|
||||
|
||||
retval = rb_funcall(a, id_cmp, 1, b);
|
||||
|
|
Загрузка…
Ссылка в новой задаче