91384 Commits

Author SHA1 Message Date
Hiroshi SHIBATA
f0dda0534b Rewrite CGI.parse with URI.decode_www_form_component
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
2025-04-24 12:15:11 +09:00
Hiroshi SHIBATA
a23ce6d3a5 Removed unused cgi library 2025-04-24 12:15:11 +09:00
Hiroshi SHIBATA
a88c5b501c Use cgi/util if that uses like CGI.escape methods 2025-04-24 12:15:11 +09:00
Aiden Fox Ivey
bf3be2723a
ZJIT: Fix README example command (#13163)
Fix README example command
2025-04-23 13:45:10 -07:00
Jean Boussier
1f090403e2 Fix comparison of signed and unsigned integers
```
../string.c:660:38: warning: comparison of integers of different signs: 'rb_atomic_t' (aka 'unsigned int') and 'int' [-Wsign-compare]
  660 |             RUBY_ASSERT(table->count < table->capacity / 2);
```
2025-04-23 18:35:00 +02:00
Nobuyoshi Nakada
7d7478c7bc
Run auto-style.rb only on ruby/ruby
`github.event.before` for newly pushed branch is all zero and cannot
check out.
2025-04-23 19:05:31 +09:00
Jean Boussier
1048b162de Eagerly store a copy of object_id in finalizer table.
This makes the finalizer table fully self contained, so GC no
longer need to delay cleaning the `obj_to_id_tbl`.
2025-04-23 11:54:29 +02:00
Hiroshi SHIBATA
a8aa83cc7b all of examples at commands/newgem_spec.rb are working on ruby repo 2025-04-23 18:09:55 +09:00
Nobuyoshi Nakada
085878a17d
Remove unexpected files [ci skip] 2025-04-23 14:17:25 +09:00
Nobuyoshi Nakada
59c7b3840d Check Unicode version of the normalization table 2025-04-23 14:14:36 +09:00
Nobuyoshi Nakada
b4417ff665 Add Encoding::UNICODE_VERSION constant 2025-04-23 14:14:36 +09:00
Xavier Noria
5f3fb35a14 Add a new spec for inherited 2025-04-23 07:07:18 +02:00
Xavier Noria
80cf292c79 Add a new spec for const_added 2025-04-23 07:07:18 +02:00
Jean Boussier
6d0dd7d863 rb_gc_impl_define_finalizer: unlock on early return 2025-04-23 07:04:41 +02:00
Damian C. Rossney
6029781984
[DOC] Update for String#split
Highlight the performance advantages of calling `string.split` with a block, instead of `string.split.each` with the same block.

Includes other minor formatting corrections.
2025-04-23 13:05:30 +09:00
Samuel Williams
c1dbd01c67
Increase fiber sleep test tolerance. (#13152) 2025-04-23 01:17:15 +00:00
Jean Boussier
7c30bd50df Add missing lock in rb_gc_impl_define_finalizer
`objspace->finalizer_table` must be synchronized,
otherwise concurrent insertion from multiple ractors
will cause a crash.

Repro:

```ruby
ractors = 5.times.map do |i|
  Ractor.new do
    100_000.times.map do
      o = Object.new
      ObjectSpace.define_finalizer(o, ->(id) {})
      o
    end
  end
end

ractors.each(&:take)
```
2025-04-22 23:23:35 +02:00
Max Bernstein
9fc5a5dbed
ZJIT: Add option to dump LIR (#13139)
Now we can dump HIR, optimized HIR, LIR, and assembly.
2025-04-22 09:17:35 -07:00
Max Bernstein
87d00142d2
Make yjit team auto-review ZJIT PRs 2025-04-22 08:50:55 -07:00
Jeremy Evans
00b1a9cde6 [ruby/pp] Rename EMPTY_HASH to EMPTY_KWHASH
https://github.com/ruby/pp/commit/efe5bc878f
2025-04-22 15:21:07 +00:00
Jeremy Evans
3ce5d89c20 [ruby/pp] Avoid an array allocation per element in list passed to seplist
The array allocation was because the keyword splat expression is
not recognized as safe by the compiler.  Also avoid unnecessary
>= method call per element.  This uses a private constant to
avoid unnecessary work at runtime.

I assume the only reason this code is needed is because v may
end with a ruby2_keywords hash that we do not want to treat as
keywords.

This issue was found by the performance warning in Ruby feature
21274.

https://github.com/ruby/pp/commit/3bf6df0e5c
2025-04-22 15:21:07 +00:00
Nobuyoshi Nakada
1628bbb18a
Ignore DEFAULT_SOURCE_DATE_EPOCH [ci skip]
Rubygems sets the date of built gems to `DEFAULT_SOURCE_DATE_EPOCH`
now unless `SOURCE_DATE_EPOCH` environment variable is set.  It is
just for the reproducible build, meaningless in our ChangeLog.
2025-04-22 21:45:42 +09:00
Nobuyoshi Nakada
349f36c527
Get rid of quadratic downloads of Unicode data files 2025-04-22 21:09:26 +09:00
Nobuyoshi Nakada
3b7dd205a5
Remove extra empty expressions
Only `class_table` values are not quoted and need to terminate %-=
literal.
2025-04-22 21:09:26 +09:00
Nobuyoshi Nakada
4e6946bda7
Assign the result of format_changelog to the changelog writer
Also, rename `format_changelog` to `changelog_formatter` since this
method does not format the changelog when called, but rather returns a
Proc that takes IO and writes the formatted changelog.
2025-04-22 21:02:29 +09:00
git
888820c581 Update bundled gems list as of 1980-01-02 2025-04-22 07:03:05 +00:00
Hiroshi SHIBATA
3a2415cc47 Skip failing example on Ubuntu runner of ruby/ruby
https://github.com/ruby/ruby/actions/runs/14585602800/job/40910453142
2025-04-22 15:34:56 +09:00
Edouard CHIN
8e8df8efb7
Remove the temporary script:
- The remaining code was not ported over as I felt it wasn't useful
  to output the Ruby related version in the context of
  running `bundle doctor`.
2025-04-22 15:34:21 +09:00
git
c3bff185a7 Update default gems list at 4634a0042e34c022984ef2d3b377ed [ci skip] 2025-04-22 02:49:52 +00:00
Hiroshi SHIBATA
4634a0042e
Mark development version for unreleased gems 2025-04-22 11:27:24 +09:00
Sutou Kouhei
067fc410fc
[ruby/strscan] Bump version
https://github.com/ruby/strscan/commit/8ff80150c4
2025-04-22 11:27:24 +09:00
Jean Boussier
e0264791f0
[ruby/json] Get rid of unused CircularDatastructure class
https://github.com/ruby/json/commit/92beca8032
2025-04-22 11:27:24 +09:00
Jeremy Evans
51d0e58772
[rubygems/rubygems] Avoid unnecessary splat allocation
Because get_push_scope is a method call, Ruby will allocate an array
for *args even though it is not necessary to do so. Using a local
variable avoids the allocation.

Found by the performance warning in Ruby feature 21274.

https://github.com/rubygems/rubygems/commit/0473c0cf32
2025-04-22 11:27:24 +09:00
Edouard CHIN
56c1a15eb7
[rubygems/rubygems] Warn if TLS 1.2 is not supported
https://github.com/rubygems/rubygems/commit/e4f70a3e4f
2025-04-22 11:27:24 +09:00
Edouard CHIN
ff2e0e4173
[rubygems/rubygems] Summarize the diagnostic
https://github.com/rubygems/rubygems/commit/40cf54d256
2025-04-22 11:27:24 +09:00
Edouard CHIN
19477ef287
[rubygems/rubygems] Diagnose the bare net/http connection
https://github.com/rubygems/rubygems/commit/38a0bdc123
2025-04-22 11:27:23 +09:00
Edouard CHIN
7a10ce8c95
[rubygems/rubygems] Diagnose the RubyGems connection
https://github.com/rubygems/rubygems/commit/bf63859e1e
2025-04-22 11:27:23 +09:00
Edouard CHIN
cba7408017
[rubygems/rubygems] Diagnose the bundler connection
https://github.com/rubygems/rubygems/commit/0aae094c89
2025-04-22 11:27:23 +09:00
Edouard CHIN
ae308ae523
[rubygems/rubygems] Diagnose when OpenSSL can't be loaded.
https://github.com/rubygems/rubygems/commit/e6aa8aabcd
2025-04-22 11:27:23 +09:00
Edouard CHIN
cda29294a9
[rubygems/rubygems] Add the bundle doctor subcommand skeleton:
- The command can either be run using:

  1. `bundle doctor --ssl`
  2. `bundle doctor ssl`

  The later is most useful when you need to specify
  custom ssl options (such as the verify mode or the
  TLS version when running the diagnostic).

  The implementation will follow in the next commits.

https://github.com/rubygems/rubygems/commit/993d12874c
2025-04-22 11:27:23 +09:00
Edouard CHIN
c2e58a9043
[rubygems/rubygems] Define bundler doctor as a subcommand
- See explanation in previous commit https://github.com/rubygems/rubygems/commit/170890befb4c

https://github.com/rubygems/rubygems/commit/8f1b5a4479
2025-04-22 11:27:23 +09:00
Edouard CHIN
ef82273c04
[rubygems/rubygems] Import the SSL Check script:
- Copy/pasted from https://github.com/rubygems/ruby-ssl-check.
  The next commits will break it down for easier reviewing.

https://github.com/rubygems/rubygems/commit/aa643a11b1
2025-04-22 11:27:23 +09:00
Edouard CHIN
89d1af9af3
Move the doctor command into a subfolder:
- Adding a new `ssl` option to bundle doctor will make the `Doctor`
  command quite bloated. The "diagnose ssl" option will also have
  children option to allow passing which host or which tls version
  you want to diagnose and I feel these options don't belong in the
  doctor command.
  So my intention in this commit is to prepare to have a new `Doctor`
  subcommand and allow for better organisation of the code:

  The command will be:

  `bundle doctor` -> Run exactly the same as before.
  `bundle doctor --ssl` -> Run the doctor command and diagnose SSL
  with default options (rubygems.org as the host and verify peer as
  the verify mode)
  `bundle doctor ssl --host github.com` -> Run the ssl subcommand and
  pass a specific host.

  This commit just renames a file in order to avoid big diff chunks.
2025-04-22 11:27:23 +09:00
Hiroshi SHIBATA
d4815d39b7 Test with Windows 2025 server 2025-04-22 10:40:23 +09:00
Aiden Fox Ivey
9106088b7e Fix typo in doc/zjit.md 2025-04-22 05:41:47 +09:00
Tanaka Akira
fa17cb75a1 [doc] update Enumerable document.
- Enhance document about #size method for Enumerable and Enumerator
- add an Enumerator example for Enumerable#drop_while
2025-04-22 01:49:41 +09:00
Takafumi ONAKA
ff689b9a7a [DOC] Fix broken link reference in NEWS.md 2025-04-21 20:19:51 +09:00
Hiroshi SHIBATA
85bab61565 Try to run only working tests 2025-04-21 12:25:41 +09:00
Hiroshi SHIBATA
d414dbae0a nmake check is crashed with windows-11-arm, we need to try test-spec 2025-04-21 12:25:41 +09:00
Hiroshi SHIBATA
99a16757ca windows-11-arm has only C drive 2025-04-21 12:25:41 +09:00