mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
* include/ruby/ruby.h: add C APIs.
VALUE rb_newobj_of(VALUE klass, VALUE flags) #define NEWOBJ_OF(obj,type,klass,flags) These allow to change a allocation strategy depending on klass or flags. * gc.c: ditto * array.c: use new C API. * bignum.c: ditto * class.c: ditto * complex.c: ditto * ext/socket/ancdata.c: ditto * ext/socket/option.c: ditto * hash.c: ditto * io.c: ditto * marshal.c: ditto * numeric.c: ditto * object.c: ditto * random.c: ditto * range.c: ditto * rational.c: ditto * re.c: ditto * string.c: ditto * struct.c: ditto [Feature #7177][Feature #7047] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f1e488e524
commit
c3a46d6aca
20 changed files with 74 additions and 42 deletions
3
range.c
3
range.c
|
@ -956,8 +956,7 @@ static VALUE
|
|||
range_dumper(VALUE range)
|
||||
{
|
||||
VALUE v;
|
||||
NEWOBJ(m, struct RObject);
|
||||
OBJSETUP(m, rb_cObject, T_OBJECT);
|
||||
NEWOBJ_OF(m, struct RObject, rb_cObject, T_OBJECT);
|
||||
|
||||
v = (VALUE)m;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue