зеркало из https://github.com/github/ruby.git
* eval.c (umethod_bind): perge unused check. [ruby-dev:22850]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5664 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
aab0773a86
Коммит
beee54c7ce
|
@ -1,3 +1,7 @@
|
|||
Tue Feb 10 16:43:50 2004 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* eval.c (umethod_bind): perge unused check. [ruby-dev:22850]
|
||||
|
||||
Tue Feb 10 14:33:08 2004 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* string.c (rb_str_match): raise TypeError when both arguments are
|
||||
|
|
6
eval.c
6
eval.c
|
@ -8712,12 +8712,6 @@ umethod_bind(method, recv)
|
|||
if (FL_TEST(data->rklass, FL_SINGLETON)) {
|
||||
rb_raise(rb_eTypeError, "singleton method called for a different object");
|
||||
}
|
||||
#if 0
|
||||
if (FL_TEST(CLASS_OF(recv), FL_SINGLETON) &&
|
||||
st_lookup(RCLASS(CLASS_OF(recv))->m_tbl, data->oid, 0)) {
|
||||
rb_raise(rb_eTypeError, "method `%s' overridden", rb_id2name(data->oid));
|
||||
}
|
||||
#endif
|
||||
if(!rb_obj_is_kind_of(recv, data->rklass)) {
|
||||
rb_raise(rb_eTypeError, "bind argument must be an instance of %s",
|
||||
rb_class2name(data->rklass));
|
||||
|
|
Загрузка…
Ссылка в новой задаче