summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-09-03 05:29:19 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-09-03 05:29:19 +0000
commit4365377d76020c5cacf03a35989f370d05f5780a (patch)
tree3351683d7f4a8991b411dee9dad61f856c42b5e0 /io.c
parent9f1e0829daa572708a0aeb3dddbd33d13cb15693 (diff)
* io.c (rb_io_popen): accept integer flags as mode.
* file.c (rb_find_file_ext): extension table can be supplied from outside. renamed. * eval.c (rb_f_require): replace rb_find_file_noext by rb_find_file_ext. * eval.c (rb_provided): should also check feature without extension. * numeric.c (flo_to_s): do not rely on decimal point to be '.' * parse.y (yylex): ternary ? can be followed by newline. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_6@1720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/io.c b/io.c
index a950c9e634..5a1f88c27c 100644
--- a/io.c
+++ b/io.c
@@ -1680,6 +1680,9 @@ rb_io_popen(str, argc, argv, klass)
if (rb_scan_args(argc, argv, "11", &pname, &pmode) == 1) {
mode = "r";
}
+ else if (FIXNUM_P(pmode)) {
+ mode = rb_io_flags_mode(NUM2INT(pmode));
+ }
else {
mode = STR2CSTR(pmode);
}