mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Reuse rb_class_new_instance_kw function
This commit is contained in:
parent
01e8d393bc
commit
fc5382d465
Notes:
git
2022-08-20 12:25:23 +09:00
1 changed files with 1 additions and 7 deletions
8
object.c
8
object.c
|
@ -1982,13 +1982,7 @@ rb_class_new_instance_kw(int argc, const VALUE *argv, VALUE klass, int kw_splat)
|
|||
VALUE
|
||||
rb_class_new_instance(int argc, const VALUE *argv, VALUE klass)
|
||||
{
|
||||
VALUE obj;
|
||||
Check_Type(klass, T_CLASS);
|
||||
|
||||
obj = rb_class_alloc(klass);
|
||||
rb_obj_call_init_kw(obj, argc, argv, RB_NO_KEYWORDS);
|
||||
|
||||
return obj;
|
||||
return rb_class_new_instance_kw(argc, argv, klass, RB_NO_KEYWORDS);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue