From ba5f3a808e0be5854ca448245fe24fcb983e650f Mon Sep 17 00:00:00 2001 From: Tilman Sauerbeck Date: Sun, 1 Apr 2007 16:18:06 +0200 Subject: [PATCH] Prefer rb_ary_new4() over rb_ary_new3(). --- ext/ext.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/ext.c b/ext/ext.c index 28bfa4c..ea620be 100644 --- a/ext/ext.c +++ b/ext/ext.c @@ -601,7 +601,7 @@ int_to_eet_chunks (int argc, VALUE *argv, VALUE self) rb_scan_args (argc, argv, "11", &tag, &type); - ary = rb_ary_new3 (1, self); + ary = rb_ary_new4 (1, &self); if (type == sym_char) cfmt = "c"; @@ -614,7 +614,7 @@ int_to_eet_chunks (int argc, VALUE *argv, VALUE self) args[1] = rb_funcall (ary, id_pack, 1, rb_str_new2 (cfmt)); chunk = rb_class_new_instance (2, args, cChunk); - return rb_ary_new3 (1, chunk); + return rb_ary_new4 (1, &chunk); } static VALUE @@ -644,7 +644,7 @@ float_to_eet_chunks (int argc, VALUE *argv, VALUE self) args[1] = rb_str_new (buf, len); chunk = rb_class_new_instance (2, args, cChunk); - return rb_ary_new3 (1, chunk); + return rb_ary_new4 (1, &chunk); } void -- 2.30.2