1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* io.c (Init_IO): remove obsolete variables: $defout, $deferr.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13617 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 2007-10-04 07:53:32 +00:00
parent 1c9a2e1154
commit 150a8b4fe0
2 changed files with 3 additions and 19 deletions

View file

@ -1,8 +1,10 @@
Thu Oct 4 16:31:17 2007 Yukihiro Matsumoto <matz@ruby-lang.org>
Thu Oct 4 16:52:20 2007 Yukihiro Matsumoto <matz@ruby-lang.org>
* re.c (kcode_setter): Perl-ish global variable `$=' no longer
effective.
* io.c (Init_IO): remove obsolete variables: $defout, $deferr.
Thu Oct 4 16:28:33 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
* encoding.c (rb_obj_encoding): returns encoding of the given object.

18
io.c
View file

@ -4151,20 +4151,6 @@ stdout_setter(VALUE val, ID id, VALUE *variable)
*variable = val;
}
static void
defout_setter(VALUE val, ID id, VALUE *variable)
{
stdout_setter(val, id, variable);
rb_warn("$defout is obsolete; use $stdout instead");
}
static void
deferr_setter(VALUE val, ID id, VALUE *variable)
{
stdout_setter(val, id, variable);
rb_warn("$deferr is obsolete; use $stderr instead");
}
static VALUE
prep_io(int fd, int mode, VALUE klass, const char *path)
{
@ -5937,10 +5923,6 @@ Init_IO(void)
orig_stdout = rb_stdout;
rb_deferr = orig_stderr = rb_stderr;
/* variables to be removed in 1.8.1 */
rb_define_hooked_variable("$defout", &rb_stdout, 0, defout_setter);
rb_define_hooked_variable("$deferr", &rb_stderr, 0, deferr_setter);
/* constants to hold original stdin/stdout/stderr */
rb_define_global_const("STDIN", rb_stdin);
rb_define_global_const("STDOUT", rb_stdout);