Project

General

Profile

Actions

Feature #17136

closed

Remove special behavior from $KCODE

Added by znz (Kazuhiro NISHIYAMA) over 3 years ago. Updated over 3 years ago.

Status:
Closed
Assignee:
-
Target version:
-
[ruby-core:99785]

Description

$SAFE is now a normal global variable with no special behavior.
I think $KCODE's special behavior is also no longer needed.
Warnings since 1.9.

% docker run -it --rm rubylang/all-ruby env ALL_RUBY_SINCE=ruby-1.4 ./all-ruby -e '$KCODE="e"; p $KCODE'
ruby-1.4.0            "EUC"
...
ruby-1.8.7-p374       "EUC"
ruby-1.9.0-0          -e:1: warning: variable $KCODE is no longer effective; ignored
                      -e:1: warning: variable $KCODE is no longer effective
                      nil
...
ruby-2.7.1            -e:1: warning: variable $KCODE is no longer effective; ignored
                      -e:1: warning: variable $KCODE is no longer effective
                      nil

Updated by matz (Yukihiro Matsumoto) over 3 years ago

We waited enough long time. Let us remove it.

Matz.

Actions #2

Updated by sawa (Tsuyoshi Sawada) over 3 years ago

  • Description updated (diff)
Actions #3

Updated by nobu (Nobuyoshi Nakada) over 3 years ago

  • Status changed from Open to Closed

Applied in changeset git|85aabef023e1a2e81c308ad98741137c73d4d80b.


[Feature #17136] Remove special behavior from $KCODE

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0