From cf51572bea16c7ec319c1dfb5a1f010530a2af9d Mon Sep 17 00:00:00 2001 From: nobu Date: Wed, 28 Sep 2005 15:58:32 +0000 Subject: * eval.c (ev_const_get), variable.c (rb_const_get_0): retry only when autoload succeeded. * variable.c (rb_autoload_load): now return true if autoload succeeded. fixed: [ruby-dev:27331] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- eval.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'eval.c') diff --git a/eval.c b/eval.c index e9b953044..0601f2d70 100644 --- a/eval.c +++ b/eval.c @@ -1837,7 +1837,7 @@ ev_const_get(cref, id, self) if (NIL_P(klass)) return rb_const_get(CLASS_OF(self), id); while (RCLASS(klass)->iv_tbl && st_lookup(RCLASS(klass)->iv_tbl, id, &result)) { if (result == Qundef) { - rb_autoload_load(klass, id); + if (!RTEST(rb_autoload_load(klass, id))) break; continue; } return result; -- cgit