We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https://docs.ruby-lang.org/ja/latest/class/StringIO.html によれば StringIO が Data を継承していることになっていますが,これはかなり昔のことであるようです。
いつ継承しなくなったのかきちんと調べていませんが,以下の実験によれば,Ruby 2.4.10 のときは Data を継承しており,Ruby 2.7.8 では継承していません。
Ruby 2.4.10:
% ruby -r stringio -e "p StringIO.ancestors" [StringIO, IO::generic_writable, IO::generic_readable, Enumerable, Data, Object, Kernel, BasicObject]
Ruby 2.7.8:
% ruby -r stringio -e "p StringIO.ancestors" [StringIO, IO::generic_writable, IO::generic_readable, Enumerable, Object, Kernel, BasicObject]
Ruby 3.3.0:
Ruby 2.x までの Data は影のような存在だったのでリファレンスマニュアルのこの誤りは大した問題ではなかったと思いますが,Ruby 3.0.0 でいったん廃止されたあと Ruby 3.2.0 で同名のクラスが導入されたために,重大問題になってしまいました。(実際,現行のリファレンスを信じて 1 時間溶かしました)
どこを直せばよいか分からないので,プルリクエスト作れません。すみません。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
https://docs.ruby-lang.org/ja/latest/class/StringIO.html
によれば StringIO が Data を継承していることになっていますが,これはかなり昔のことであるようです。
いつ継承しなくなったのかきちんと調べていませんが,以下の実験によれば,Ruby 2.4.10 のときは Data を継承しており,Ruby 2.7.8 では継承していません。
Ruby 2.4.10:
Ruby 2.7.8:
Ruby 3.3.0:
Ruby 2.x までの Data は影のような存在だったのでリファレンスマニュアルのこの誤りは大した問題ではなかったと思いますが,Ruby 3.0.0 でいったん廃止されたあと Ruby 3.2.0 で同名のクラスが導入されたために,重大問題になってしまいました。(実際,現行のリファレンスを信じて 1 時間溶かしました)
どこを直せばよいか分からないので,プルリクエスト作れません。すみません。
The text was updated successfully, but these errors were encountered: