diff options
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 7 |
1 files changed, 1 insertions, 6 deletions
@@ -7878,12 +7878,7 @@ rb_obj_display(int argc, VALUE *argv, VALUE self) { VALUE out; - if (argc == 0) { - out = rb_stdout; - } - else { - rb_scan_args(argc, argv, "01", &out); - } + out = (!rb_check_arity(argc, 0, 1) ? rb_stdout : argv[0]); rb_io_write(out, self); return Qnil; |