summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
Diffstat (limited to 'io.c')
-rw-r--r--io.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/io.c b/io.c
index cbc4719094..725e072fd9 100644
--- a/io.c
+++ b/io.c
@@ -2938,11 +2938,7 @@ rb_io_s_pipe()
r = prep_stdio(rb_fdopen(pipes[0], "r"), FMODE_READABLE, rb_cIO);
w = prep_stdio(rb_fdopen(pipes[1], "w"), FMODE_WRITABLE|FMODE_SYNC, rb_cIO);
- ary = rb_ary_new2(2);
- rb_ary_push(ary, r);
- rb_ary_push(ary, w);
-
- return ary;
+ return rb_assoc_new(r, w);
#else
rb_notimplement();
return Qnil; /* not reached */