summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-11-16[ruby/date] `Date._<format>(nil)` should return an empty HashJean Boussier
Fix: https://github.com/ruby/date/issues/39 This is how versions previous to 3.2.1 behaved and Active Support currently rely on this behavior. https://github.com/rails/rails/blob/90357af08048ef5076730505f6e7b14a81f33d0c/activesupport/lib/active_support/values/time_zone.rb#L383-L384 Any Rails application upgrading to date `3.2.1` might run into unexpected errors. https://github.com/ruby/date/commit/8f2d7a0c7e
2021-11-16Temporary ignored the failing specs for DateHiroshi SHIBATA
2021-11-16[ruby/nkf] Fix a typo [ci skip]Nobuyoshi Nakada
https://github.com/ruby/nkf/commit/18c118c83c
2021-11-16[ruby/ipaddr] Bump version to 1.2.3Akinori MUSHA
https://github.com/ruby/ipaddr/commit/37007e7812
2021-11-16[ruby/date] Add length limit option for methods that parses date stringsYusuke Endoh
`Date.parse` now raises an ArgumentError when a given date string is longer than 128. You can configure the limit by giving `limit` keyword arguments like `Date.parse(str, limit: 1000)`. If you pass `limit: nil`, the limit is disabled. Not only `Date.parse` but also the following methods are changed. * Date._parse * Date.parse * DateTime.parse * Date._iso8601 * Date.iso8601 * DateTime.iso8601 * Date._rfc3339 * Date.rfc3339 * DateTime.rfc3339 * Date._xmlschema * Date.xmlschema * DateTime.xmlschema * Date._rfc2822 * Date.rfc2822 * DateTime.rfc2822 * Date._rfc822 * Date.rfc822 * DateTime.rfc822 * Date._jisx0301 * Date.jisx0301 * DateTime.jisx0301 https://github.com/ruby/date/commit/3959accef8
2021-11-16[ruby/net-protocol] Update the required ruby versionNobuyoshi Nakada
https://github.com/ruby/net-protocol/commit/d4982420e6
2021-11-16[ruby/set] Bump the version to 1.0.2Akinori MUSHA
https://github.com/ruby/set/commit/db2ebc946d
2021-11-16[ruby/io-wait] Fix dependency for ruby 2.6Nobuyoshi Nakada
https://github.com/ruby/io-wait/commit/2eb3841e9c
2021-11-16[ruby/io-wait] Allow earlier versionsNobuyoshi Nakada
https://github.com/ruby/io-wait/commit/1060f9348c
2021-11-16[ruby/io-wait] Disable ractor test which is meaningless on earlier versionsNobuyoshi Nakada
https://github.com/ruby/io-wait/commit/e8e1e99d4c
2021-11-16[ruby/io-wait] Fix backward compatibility with earlier versionsNobuyoshi Nakada
https://github.com/ruby/io-wait/commit/898248931f
2021-11-16[ruby/io-wait] Use `omit` as per test-unitNobuyoshi Nakada
https://github.com/ruby/io-wait/commit/1f59f7b02f
2021-11-16Merge the master branch of rubygems repoHiroshi SHIBATA
Picked from https://github.com/rubygems/rubygems/commit/4b498709a015a94e14a3852a1841a7a3e669133d
2021-11-16Ignore LUCENSE files of standard libraries for sync targetHiroshi SHIBATA
2021-11-16Added LICENSE entry of vendored net-http-persistent to LEGALHiroshi SHIBATA
2021-11-16Added LICENSE entry of vendored connection_pool to LEGALHiroshi SHIBATA
2021-11-16Added LICENSE entry of vendored molinillo to LEGALHiroshi SHIBATA
2021-11-16Added LICENSE entry of vendored thor to LEGALHiroshi SHIBATA
2021-11-16Merge digest-3.0.3.pre3 and ↵Hiroshi SHIBATA
https://github.com/ruby/digest/commit/efd76821b8a467c193c753104c29b476debbb2c9
2021-11-16[ruby/digest] Abort loading if being loaded by gem/bundle pre Ruby 3.0.3Akinori MUSHA
https://github.com/ruby/digest/commit/efd76821b8
2021-11-16[ruby/digest] Avoid null pointer subtraction in digest/md5xtkoba
Fixes warning on Clang 13. Fixes [Bug #18076] https://github.com/ruby/digest/commit/32135c7487
2021-11-16Support preview releaseNARUSE, Yui
Also add tag property.
2021-11-15Enhanced RDoc for Integer (#5118)Burdette Lamar
Treats: #allbits? #anybits? #nobits? #succ #pred #chr` #to_s #+ #- Notes: Merged-By: BurdetteLamar <[email protected]>
2021-11-15Add Aaron Patterson (@tenderlove) to YJIT code owners (#5119)Maxime Chevalier-Boisvert
Notes: Merged-By: maximecb <[email protected]>
2021-11-15Sync test_http_request.rb after fix to net-httpJeremy Evans
2021-11-16* 2021-11-16 [ci skip]git
2021-11-16[ruby/net-http] Fix tests after change to allow HEAD to send Accept-EncodingJeremy Evans
https://github.com/ruby/net-http/commit/ca7bb8c51c
2021-11-15test/ruby/test_m17n.rb: skip a test that breaks another testYusuke Endoh
See https://bugs.ruby-lang.org/issues/18338
2021-11-15Ignore extentions of bundled gems for testingHiroshi SHIBATA
2021-11-15Relax extention name for macOSHiroshi SHIBATA
2021-11-14Skip string allocation in benchmark/time_at.ymlTakashi Kokubun
and also drop a weird newline from benchmark/array_sample.yml.
2021-11-15add benchmark/time_at.ymlKoichi Sasada
``` ruby_2_6 ruby_2_7 ruby_3_0 master modified Time.at(0) 12.362M 11.015M 9.499M 6.615M 9.000M i/s - 32.115M times in 2.597946s 2.915517s 3.380725s 4.854651s 3.568234s Time.at(0, 500) 7.542M 7.136M 8.252M 5.707M 5.646M i/s - 20.713M times in 2.746279s 2.902556s 2.510166s 3.629644s 3.668854s Time.at(0, in: "+09:00") 1.426M 1.346M 1.565M 1.674M 1.667M i/s - 4.240M times in 2.974049s 3.149753s 2.709416s 2.533043s 2.542853s ``` ``` ruby_2_6: ruby 2.6.7p150 (2020-12-09 revision 67888) [x86_64-linux] ruby_2_7: ruby 2.7.3p140 (2020-12-09 revision 9b884df6dd) [x86_64-linux] ruby_3_0: ruby 3.0.3p150 (2021-11-06 revision 6d540c1b98) [x86_64-linux] master: ruby 3.1.0dev (2021-11-13T20:48:57Z master fc456adc6a) [x86_64-linux] modified: ruby 3.1.0dev (2021-11-15T01:12:51Z mandatory_only_bui.. b0228446db) [x86_64-linux] ``` Notes: Merged: https://github.com/ruby/ruby/pull/5112
2021-11-15Use `Primitive.mandatory_only?` for `Time.at`Koichi Sasada
Notes: Merged: https://github.com/ruby/ruby/pull/5112
2021-11-15add benchmark/array_sample.ymlKoichi Sasada
``` ruby_2_6 ruby_2_7 ruby_3_0 master modified ary.sample 32.113M 30.146M 11.162M 10.539M 26.620M i/s - 64.882M times in 2.020428s 2.152296s 5.812981s 6.156398s 2.437325s ary.sample(2) 9.420M 8.987M 7.500M 6.973M 7.191M i/s - 25.170M times in 2.672085s 2.800616s 3.355896s 3.609534s 3.500108s ``` ``` ruby_2_6: ruby 2.6.7p150 (2020-12-09 revision 67888) [x86_64-linux] ruby_2_7: ruby 2.7.3p140 (2020-12-09 revision 9b884df6dd) [x86_64-linux] ruby_3_0: ruby 3.0.3p150 (2021-11-06 revision 6d540c1b98) [x86_64-linux] master: ruby 3.1.0dev (2021-11-13T20:48:57Z master fc456adc6a) [x86_64-linux] modified: ruby 3.1.0dev (2021-11-15T01:12:51Z mandatory_only_bui.. b0228446db) [x86_64-linux] ``` Notes: Merged: https://github.com/ruby/ruby/pull/5112
2021-11-15Use `Primitive.mandatory_only?` for `Array#sample`Koichi Sasada
Notes: Merged: https://github.com/ruby/ruby/pull/5112
2021-11-15`Primitive.mandatory_only?` for fast pathKoichi Sasada
Compare with the C methods, A built-in methods written in Ruby is slower if only mandatory parameters are given because it needs to check the argumens and fill default values for optional and keyword parameters (C methods can check the number of parameters with `argc`, so there are no overhead). Passing mandatory arguments are common (optional arguments are exceptional, in many cases) so it is important to provide the fast path for such common cases. `Primitive.mandatory_only?` is a special builtin function used with `if` expression like that: ```ruby def self.at(time, subsec = false, unit = :microsecond, in: nil) if Primitive.mandatory_only? Primitive.time_s_at1(time) else Primitive.time_s_at(time, subsec, unit, Primitive.arg!(:in)) end end ``` and it makes two ISeq, ``` def self.at(time, subsec = false, unit = :microsecond, in: nil) Primitive.time_s_at(time, subsec, unit, Primitive.arg!(:in)) end def self.at(time) Primitive.time_s_at1(time) end ``` and (2) is pointed by (1). Note that `Primitive.mandatory_only?` should be used only in a condition of an `if` statement and the `if` statement should be equal to the methdo body (you can not put any expression before and after the `if` statement). A method entry with `mandatory_only?` (`Time.at` on the above case) is marked as `iseq_overload`. When the method will be dispatch only with mandatory arguments (`Time.at(0)` for example), make another method entry with ISeq (2) as mandatory only method entry and it will be cached in an inline method cache. The idea is similar discussed in https://bugs.ruby-lang.org/issues/16254 but it only checks mandatory parameters or more, because many cases only mandatory parameters are given. If we find other cases (optional or keyword parameters are used frequently and it hurts performance), we can extend the feature. Notes: Merged: https://github.com/ruby/ruby/pull/5112
2021-11-15Revert "test/ruby/test_m17n.rb: Run a test under assert_separately"Yusuke Endoh
This reverts commit a698181021c11711dc56b74dacbdebc2895b5384. It failed on macos for a unknown problem. ``` 1) Error: TestM17N#test_object_inspect_external: Encoding::ConverterNotFoundError: code converter not found (US-ASCII to UTF-16BE) /Users/runner/work/ruby/ruby/src/test/ruby/test_m17n.rb:312:in `encode' /Users/runner/work/ruby/ruby/src/test/ruby/test_m17n.rb:312:in `inspect' /Users/runner/work/ruby/ruby/src/test/ruby/test_m17n.rb:315:in `inspect' /Users/runner/work/ruby/ruby/src/test/ruby/test_m17n.rb:315:in `<main>' /Users/runner/work/ruby/ruby/src/test/ruby/test_m17n.rb:299:in `test_object_inspect_external' ``` https://github.com/ruby/ruby/runs/4207871418?check_suite_focus=true
2021-11-15Revert "Enhanced RDoc for Integer (#5099)"Yusuke Endoh
This reverts commit fc456adc6a62d09b755243b8c8f190934b9965d6. It broke the CI check. https://github.com/ruby/ruby/runs/4207922247?check_suite_focus=true#step:3:4 ``` numeric.c:3518: * 255.chr(Encoding::UTF_8) # => "ÿ" Error: Process completed with exit code 1. ```
2021-11-15test/ruby/test_m17n.rb: Run a test under assert_separatelyYusuke Endoh
The test uses `Encoding.default_external = Encoding::UTF_16BE`, which may add a wrongly UTF_16BE-encoded path to $LOADED_FEATURES (depending on the order of tests). Unfortunately this breaks another test: http://ci.rvm.jp/results/trunk-test@ruby-sky1/3711615 ``` /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb:11:in `===': incompatible encoding regexp match (US-ASCII regexp with UTF-16BE string) (Encoding::CompatibilityError) ``` According to @naruse-san, we don't pay effort to such a case, so this change just avoids the issue by running the test in question under another process. Co-Authored-By: Koichi Sasada <[email protected]>
2021-11-15* 2021-11-15 [ci skip]git
2021-11-15`rb_vm_lvar_exposed()` is PUREFUNCKoichi Sasada
This function is used in `rb_vm_lvar()` and this function can be unsed (generated into *.rbinc files automatically). `rb_vm_lvar()` is already declared as a PUREFUNC, but `rb_vm_lvar_exposed()` is not a PUREFUNC, so `rb_vm_lvar_exposed()` is remained even if it is unused. Notes: Merged: https://github.com/ruby/ruby/pull/5113
2021-11-13Enhanced RDoc for Integer (#5099)Burdette Lamar
Treats: #allbits? #anybits? #nobits? #succ #pred #chr` #to_s #+ #- Notes: Merged-By: BurdetteLamar <[email protected]>
2021-11-14show encoding for each pathKoichi Sasada
2021-11-14* 2021-11-14 [ci skip]git
2021-11-14test/io/console/test_io_console.rb: dump debug output to stderrYusuke Endoh
make test-all in parallel mode seems to hide stdout
2021-11-12parse.y: Fix memory leak at parse errorYusuke Endoh
Local variable tables might leak at the parse error. Notes: Merged: https://github.com/ruby/ruby/pull/5111
2021-11-12test/ruby/test_jit.rb: suppress a false-positive warningYusuke Endoh
It reports "opt_regexpmatch2 insn is not included", but actually it is included. This is due to a known bug of ISeq#to_a on which this check depends. https://bugs.ruby-lang.org/issues/18269
2021-11-12test/io/console/test_io_console.rb: add debug codeYusuke Endoh
to debug the following failure http://ci.rvm.jp/results/trunk-test@ruby-sky1/3708240 ``` /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb:10:in `===': incompatible encoding regexp match (US-ASCII regexp with UTF-16BE string) (Encoding::CompatibilityError) /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb:10:in `each' /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb:10:in `grep' /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb:10:in `<class:TestIO_Console>' /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb:9:in `<top (required)>' <internal:/tmp/ruby/v3/src/trunk-test/lib/rubygems/core_ext/kernel_require.rb>:85:in `require' <internal:/tmp/ruby/v3/src/trunk-test/lib/rubygems/core_ext/kernel_require.rb>:85:in `require' /tmp/ruby/v3/src/trunk-test/tool/lib/test/unit/parallel.rb:122:in `run' /tmp/ruby/v3/src/trunk-test/tool/lib/test/unit/parallel.rb:211:in `<main>' running file: /tmp/ruby/v3/src/trunk-test/test/io/console/test_io_console.rb ```
2021-11-12Update bundled_gems at 2021-11-12git
2021-11-12Rework implementation of `IO::Buffer.for(string)` to use string locking.Samuel Williams
Notes: Merged: https://github.com/ruby/ruby/pull/5109