diff --git a/ext/coverage/coverage.c b/ext/coverage/coverage.c index 1519b559cdafc1..74d9f3ea4655fe 100644 --- a/ext/coverage/coverage.c +++ b/ext/coverage/coverage.c @@ -352,7 +352,6 @@ rb_coverage_peek_result(VALUE klass) if (!RTEST(coverages)) { rb_raise(rb_eRuntimeError, "coverage measurement is not enabled"); } - OBJ_WB_UNPROTECT(coverages); rb_hash_foreach(coverages, coverage_peek_result_i, ncoverages); diff --git a/id_table.c b/id_table.c index eb8477237ea622..4629af553505b7 100644 --- a/id_table.c +++ b/id_table.c @@ -353,7 +353,7 @@ const rb_data_type_t rb_managed_id_table_type = { .wrap_struct_name = "VM/managed_id_table", .function = { .dmark = NULL, // Nothing to mark - .dfree = (RUBY_DATA_FUNC)managed_id_table_free, + .dfree = managed_id_table_free, .dsize = managed_id_table_memsize, }, .flags = RUBY_TYPED_FREE_IMMEDIATELY | RUBY_TYPED_WB_PROTECTED | RUBY_TYPED_EMBEDDABLE, diff --git a/lib/cgi.rb b/lib/cgi.rb index b041c1bed13b1c..bb306d2e0644cf 100644 --- a/lib/cgi.rb +++ b/lib/cgi.rb @@ -2,6 +2,6 @@ require "cgi/escape" warn <<-WARNING, uplevel: Gem::BUNDLED_GEMS.uplevel if $VERBOSE -CGI library is removed from Ruby 3.5. Please use cgi/escape instead for CGI.escape and CGI.unescape features. +CGI library is removed from Ruby 4.0. Please use cgi/escape instead for CGI.escape and CGI.unescape features. If you need to use the full features of CGI library, Please install cgi gem. WARNING diff --git a/lib/cgi/util.rb b/lib/cgi/util.rb index 389a04acd21f05..50a2e91665e000 100644 --- a/lib/cgi/util.rb +++ b/lib/cgi/util.rb @@ -2,6 +2,6 @@ require "cgi/escape" warn <<-WARNING, uplevel: Gem::BUNDLED_GEMS.uplevel if $VERBOSE -CGI::Util is removed from Ruby 3.5. Please use cgi/escape instead for CGI.escape and CGI.unescape features. +CGI::Util is removed from Ruby 4.0. Please use cgi/escape instead for CGI.escape and CGI.unescape features. If you are using CGI.parse, please install and use the cgi gem instead. WARNING diff --git a/lib/erb/util.rb b/lib/erb/util.rb index 9c3d186edefb62..adeb695aa81fec 100644 --- a/lib/erb/util.rb +++ b/lib/erb/util.rb @@ -2,8 +2,8 @@ # Load CGI.escapeHTML and CGI.escapeURIComponent. # CRuby: -# cgi.gem v0.1.0+ (Ruby 2.7-3.4) and Ruby 3.5+ stdlib have 'cgi/escape' and CGI.escapeHTML. -# cgi.gem v0.3.3+ (Ruby 3.2-3.4) and Ruby 3.5+ stdlib have CGI.escapeURIComponent. +# cgi.gem v0.1.0+ (Ruby 2.7-3.4) and Ruby 4.0+ stdlib have 'cgi/escape' and CGI.escapeHTML. +# cgi.gem v0.3.3+ (Ruby 3.2-3.4) and Ruby 4.0+ stdlib have CGI.escapeURIComponent. # JRuby: cgi.gem has a Java extension 'cgi/escape'. # TruffleRuby: lib/truffle/cgi/escape.rb requires 'cgi/util'. require 'cgi/escape' diff --git a/test/openssl/test_ssl.rb b/test/openssl/test_ssl.rb index e700e53e3b58c0..5082dadd1b7971 100644 --- a/test/openssl/test_ssl.rb +++ b/test/openssl/test_ssl.rb @@ -2325,12 +2325,12 @@ def test_export_keying_material end end - # OpenSSL::Buffering requires $/ accessible from non-main Ractors (Ruby 3.5) + # OpenSSL::Buffering requires $/ accessible from non-main Ractors (Ruby 4.0) # https://bugs.ruby-lang.org/issues/21109 # # Hangs on Windows # https://bugs.ruby-lang.org/issues/21537 - if respond_to?(:ractor) && RUBY_VERSION >= "3.5" && RUBY_PLATFORM !~ /mswin|mingw/ + if respond_to?(:ractor) && RUBY_VERSION >= "4.0" && RUBY_PLATFORM !~ /mswin|mingw/ ractor def test_ractor_client start_server { |port|