Граф коммитов

84342 Коммитов

Автор SHA1 Сообщение Дата
Nobuyoshi Nakada 4bb8f8582f [Feature #20244] Show the conflicting another chdir block 2024-03-14 18:33:28 +09:00
Nobuyoshi Nakada 8fe86feecd [Feature #20244] Extract `chdir_lock` and its stuffs 2024-03-14 18:33:28 +09:00
Nobuyoshi Nakada 1ad366134d
[Feature #20293] Add `Warning.categories` 2024-03-14 17:56:55 +09:00
Nobuyoshi Nakada f36a71e269 [Bug #20307] Fix `Hash#update` to make frozen copy of string keys 2024-03-14 17:49:37 +09:00
Nobuyoshi Nakada cd774f4ab9 Extract `RHASH_STRING_KEY_P` 2024-03-14 17:49:37 +09:00
Nobuyoshi Nakada c1279a3da5 Extract `RHASH_IDENTHASH_P` 2024-03-14 17:49:37 +09:00
Hiroshi SHIBATA fdf1fa5f5f
Revert "Warn ostruct for Ruby 3.5"
This reverts commit 1acbdc76d6.

I need to remove ostruct from Rake or fix bundler example.

https://github.com/ruby/ruby/actions/runs/8277371220/job/22647605911#step:11:3428
2024-03-14 17:41:24 +09:00
Hiroshi SHIBATA 1acbdc76d6
Warn ostruct for Ruby 3.5 2024-03-14 17:07:23 +09:00
git d5e9942ad2 Update bundled gems list at 04fc9f87be [ci skip] 2024-03-14 07:28:19 +00:00
Hiroshi SHIBATA 04fc9f87be
Use released version of bigdecimal 2024-03-14 16:27:37 +09:00
Hiroshi SHIBATA 1cffaf1c25
minitest-5.22.3 tag is not available yet 2024-03-14 15:12:03 +09:00
git cc141b619e Update bundled gems list at 07b40044ad [ci skip] 2024-03-14 05:22:55 +00:00
Hiroshi SHIBATA 07b40044ad
Use released version of minitest 2024-03-14 14:21:50 +09:00
Nobuyoshi Nakada 578f96afb5 [ruby/stringio] [DOC] Package rdoc files
https://github.com/ruby/stringio/commit/8522c90e4b
2024-03-14 04:30:28 +00:00
Nobuyoshi Nakada c913f3347c [ruby/stringio] [DOC] Add missing documents
https://github.com/ruby/stringio/commit/9cc1dfa19c
2024-03-14 04:30:28 +00:00
Nobuyoshi Nakada 35706c608c [ruby/stringio] [DOC] Add rdoc task
https://github.com/ruby/stringio/commit/5dd52d4aec
2024-03-14 04:30:27 +00:00
Nobuyoshi Nakada b01d319ec8 [ruby/fcntl] [DOC] Package files for RDoc
https://github.com/ruby/fcntl/commit/b946e505f1
2024-03-14 04:19:46 +00:00
Nobuyoshi Nakada e394f5539e [ruby/fcntl] [DOC] Package document files
https://github.com/ruby/fcntl/commit/ed2d725505
2024-03-14 04:01:24 +00:00
Nobuyoshi Nakada 4ae67b1ab5 [ruby/fcntl] [DOC] Add missing documents
https://github.com/ruby/fcntl/commit/a201ed6682
2024-03-14 03:49:40 +00:00
Nobuyoshi Nakada 085daf4840 [ruby/fcntl] [DOC] Add task and files for RDoc
https://github.com/ruby/fcntl/commit/1c7c70fa5d
2024-03-14 03:49:40 +00:00
Nobuyoshi Nakada 5fe1853e9b [ruby/fcntl] Reduce duplicate `O_ACCMODE` definitions
https://github.com/ruby/fcntl/commit/6a6442a7f8
2024-03-14 03:49:38 +00:00
Nobuyoshi Nakada d49b41566b [ruby/fcntl] [DOC] Remove redundant directives
https://github.com/ruby/fcntl/commit/a99909a90f
2024-03-14 03:49:37 +00:00
Kevin Newton 00c32f606a [PRISM] Do not send numbered parameters into eval 2024-03-13 19:01:43 -04:00
Kevin Newton 2f8cbd6431 [PRISM] Handle ambiguous_param0 for it and numbered parameters 2024-03-13 19:01:33 -04:00
Kevin Newton 7c9e6eab89 Handle nth ref too big 2024-03-13 19:01:21 -04:00
Peter Zhu 42bfbe9aa6 Remove unused size_pool_edge_names 2024-03-13 14:50:44 -04:00
Burdette Lamar 76f9cfd0b9
[DOC] Array doc (#10199) 2024-03-13 14:50:18 -04:00
Kevin Newton 2cfcebb2a8 [ruby/prism] Warn for maximum number variables
https://github.com/ruby/prism/commit/2cdbf81c95
2024-03-13 18:35:18 +00:00
Kevin Newton f0b5d0ad54 [PRISM] Turn on more tests 2024-03-13 14:25:03 -04:00
Kevin Newton fa009e392c [PRISM] Static literal strings should be fstrings 2024-03-13 14:24:53 -04:00
Kevin Newton e6a1baad48 [PRISM] Fix compiling duplicated keywords 2024-03-13 14:13:19 -04:00
Koichi ITO a5ac27e9e9 [ruby/prism] Turn on heredocs nested test for `Prism::Translation::Parser`
This PR enables the heredocs_nested.txt that was previously skipped testing.

https://github.com/ruby/prism/commit/9c54f7f10b
2024-03-13 17:35:31 +00:00
Kevin Newton c17f33aa42 [ruby/prism] Only use e suffix for floats if followed by +, -, or digit
https://github.com/ruby/prism/commit/164de502c9
2024-03-13 17:00:03 +00:00
Koichi ITO bf17093a42 [ruby/prism] Fix diagnostic incompatibility for `Prism::Translation::Parser`
In the case of the `**` and `&` ambiguous prefixes, incompatibilities
remained among https://github.com/ruby/prism/issues/2513.

https://github.com/ruby/prism/commit/3b8b231aae
2024-03-13 16:51:37 +00:00
Takashi Kokubun 207b002392
YJIT: Fallback cfunc varg splat for ruby2_keywords (#10226) 2024-03-13 12:22:35 -04:00
Nobuyoshi Nakada c843afbf6f Chomp last punctuations from descriptions for `-h`
The following parts will not be shown for `-h` option.  And not to
reach 80 columns.  Some terminal emulators (Windows command prompt at
least) wrap the cursor to the next line when reaching the rightmost
column, before exceeding.
2024-03-14 01:19:57 +09:00
Kevin Newton a05dfbd405
[PRISM] Remove ssize_t definition from prism 2024-03-13 12:06:48 -04:00
Kevin Newton 4dd9602c6f [ruby/prism] Remove ssize_t usage
https://github.com/ruby/prism/commit/64c4f1268b
2024-03-13 16:06:13 +00:00
Kevin Newton 572e791567 [ruby/prism] FSL follow-up
https://github.com/ruby/prism/commit/097fd2a54f
2024-03-13 16:05:46 +00:00
Jean Boussier 53a77d9b90 [ruby/prism] Change `frozen_string_literal` to be a tri-state
An explicit `false` is not equivalent to the comment being missing,
because the default can be switched with a runtime flag:

```bash
$ ruby --enable-frozen-string-literal -e 'p "foo".frozen?'
true
```

https://github.com/ruby/prism/commit/4660f58775
2024-03-13 16:03:24 +00:00
Koichi ITO 0f076fa520 [ruby/prism] Fix an AST and token incompatibility for `Prism::Translation::Parser`
This PR fixes an AST and token incompatibility between Parser gem and `Prism::Translation::Parser`
for empty xstring literal.

## Parser gem (Expected)

```console
$ bundle exec ruby -Ilib -rparser/ruby33 -ve \
'buf = Parser::Source::Buffer.new("/tmp/s.rb"); buf.source = "``"; p Parser::Ruby33.new.tokenize(buf)'
ruby 3.3.0 (2023-12-25 revision https://github.com/ruby/prism/commit/5124f9ac75) [x86_64-darwin22]
[s(:xstr), [], [[:tXSTRING_BEG, ["`", #<Parser::Source::Range /tmp/s.rb 0...1>]],
[:tSTRING_END, ["`", #<Parser::Source::Range /tmp/s.rb 1...2>]]]]
```

## `Prism::Translation::Parser` (Actual)

Previously, the AST and tokens returned by the Parser gem were different:

```console
$ bunele exec ruby -Ilib -rprism -rprism/translation/parser33 -ve \
'buf = Parser::Source::Buffer.new("/tmp/s.rb"); buf.source = "``"; p Prism::Translation::Parser33.new.tokenize(buf)'
ruby 3.3.0 (2023-12-25 revision https://github.com/ruby/prism/commit/5124f9ac75) [x86_64-darwin22]
[s(:xstr, s(:str, "")), [], [[:tBACK_REF2, ["`", #<Parser::Source::Range /tmp/s.rb 0...1>]],
[:tSTRING_END, ["`", #<Parser::Source::Range /tmp/s.rb 1...2>]]]]
```

After this correction, the AST and tokens returned by the Parser gem are the same:

```console
$ bundle exec ruby -Ilib -rprism -rprism/translation/parser33 -ve \
'buf = Parser::Source::Buffer.new("/tmp/s.rb"); buf.source = "``"; p Prism::Translation::Parser33.new.tokenize(buf)'
ruby 3.3.0 (2023-12-25 revision https://github.com/ruby/prism/commit/5124f9ac75) [x86_64-darwin22]
[s(:xstr), [], [[:tXSTRING_BEG, ["`", #<Parser::Source::Range /tmp/s.rb 0...1>]],
[:tSTRING_END, ["`", #<Parser::Source::Range /tmp/s.rb 1...2>]]]]
```

https://github.com/ruby/prism/commit/4ac89dcbb5
2024-03-13 16:02:10 +00:00
Jun Aruga eb4082284a [ruby/openssl] test_provider.rb: Make a legacy provider test optional.
In some cases such as OpenSSL package in FreeBSD[1], the legacy provider is not
installed intentionally. So, we omit a test depending the legacy provider if the
legacy provider is not loadable.

For the test_openssl_provider_names test, we use base provider[2] instead of
legacy provider, because we would expect the base provider is always loadable
in OpenSSL 3 for now.

* [1] https://www.freshports.org/security/openssl/
* [2] https://wiki.openssl.org/index.php/OpenSSL_3.0#Providers

https://github.com/ruby/openssl/commit/7223da7730
2024-03-13 15:47:27 +00:00
Jun Aruga 171791426b [ruby/openssl] Revert "omit tests related legacy provider"
This reverts commit https://github.com/ruby/openssl/commit/9b7543d58869.

The case not providing the legacy provider can happen not only in FreeBSD but
also in other platforms. The fix is addressed in the next commit.

https://github.com/ruby/openssl/commit/8c26fc26a1
2024-03-13 15:47:26 +00:00
Jun Aruga dd5e625d7b [ruby/openssl] test_asn1.rb: Remove the assertions of the time string format without second.
This commit fixes the following errors in the tests.
Because the OpenSSL project changed the code to make the time string format
without second invalid. So, we drop the assertions.

```
1) Error: test_generalizedtime(OpenSSL::TestASN1): OpenSSL::ASN1::ASN1Error: generalizedtime is too short
/home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode'
/home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode_test'
/home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:433:in `test_generalizedtime'
     430:       OpenSSL::ASN1::GeneralizedTime.new(Time.utc(9999, 9, 8, 23, 43, 39))
     431:     # LibreSSL 3.6.0 requires the seconds element
     432:     return if libressl?
  => 433:     decode_test B(%w{ 18 0D }) + "201612081934Z".b,
     434:       OpenSSL::ASN1::GeneralizedTime.new(Time.utc(2016, 12, 8, 19, 34, 0))
     435:     # not implemented
     436:     # decode_test B(%w{ 18 13 }) + "https://github.com/ruby/openssl/commit/201612081934+0930".b,

2) Error: test_utctime(OpenSSL::TestASN1): OpenSSL::ASN1::ASN1Error: utctime is too short
/home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode'
/home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:698:in `decode_test'
/home/runner/work/ruby-openssl/ruby-openssl/test/openssl/test_asn1.rb:411:in `test_utctime'
     408:     end
     409:     # Seconds is omitted. LibreSSL 3.6.0 requires it
     410:     return if libressl?
  => 411:     decode_test B(%w{ 17 0B }) + "1609082343Z".b,
     412:       OpenSSL::ASN1::UTCTime.new(Time.utc(2016, 9, 8, 23, 43, 0))
     413:     # not implemented
     414:     # decode_test B(%w{ 17 11 }) + "https://github.com/ruby/openssl/commit/500908234339+0930".b,
```

https://github.com/ruby/openssl/commit/2e826d5715
2024-03-13 15:19:40 +00:00
Kevin Newton 22217e70c2
[PRISM] Handle parentheses in patterns in prism 2024-03-13 10:06:19 -04:00
Peter Zhu c6089b5654 Don't allow SHAPE_T_OBJECT in rb_shape_alloc_new_child 2024-03-13 09:55:52 -04:00
Peter Zhu 88373fe2e8 Update cruby_bindings.inc.rs 2024-03-13 09:55:52 -04:00
Peter Zhu 3896f9940e Make special const and too complex shapes before T_OBJECT shapes 2024-03-13 09:55:52 -04:00
Peter Zhu 6b0434c0f7 Don't create per size pool shapes for non-T_OBJECT 2024-03-13 09:55:52 -04:00
Peter Zhu 6ad347a105 Don't directly read the SIZE_POOL_COUNT in shapes
This removes the assumption about SIZE_POOL_COUNT for shapes.
2024-03-13 09:55:52 -04:00