mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
load.c: use rb_load_internal0
* load.c (rb_require_internal): use rb_load_internal0 not to raise a exception to be caught. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51451 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
b00ba0a957
commit
9a0f5286d7
2 changed files with 10 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
|||
Fri Jul 31 21:34:49 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* load.c (rb_require_internal): use rb_load_internal0 not to raise
|
||||
a exception to be caught.
|
||||
|
||||
Thu Jul 30 13:19:54 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* variable.c (rb_const_get_0): warn deprecated constant reference.
|
||||
|
|
8
load.c
8
load.c
|
@ -1006,7 +1006,7 @@ rb_require_internal(VALUE fname, int safe)
|
|||
else {
|
||||
switch (found) {
|
||||
case 'r':
|
||||
rb_load_internal(path, 0);
|
||||
state = rb_load_internal0(th, path, 0);
|
||||
break;
|
||||
|
||||
case 's':
|
||||
|
@ -1015,8 +1015,10 @@ rb_require_internal(VALUE fname, int safe)
|
|||
rb_ary_push(ruby_dln_librefs, LONG2NUM(handle));
|
||||
break;
|
||||
}
|
||||
rb_provide_feature(path);
|
||||
result = TAG_RETURN;
|
||||
if (!state) {
|
||||
rb_provide_feature(path);
|
||||
result = TAG_RETURN;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue