83249 Commits

Author SHA1 Message Date
Hiroshi SHIBATA
772afa00b5 Pend tests on Travis CI 2024-01-24 13:50:16 +09:00
Martin Emde
01f9766aa0 Ensure File.open applies default umask on gem extract 2024-01-24 13:50:16 +09:00
Nobuyoshi Nakada
2defa9f4ae
[DOC] Elaborate exceptional behaviors on Windows 2024-01-24 12:44:40 +09:00
Nobuyoshi Nakada
769bb924b2
[DOC] Tips for space containing exe_path 2024-01-24 12:44:40 +09:00
Nobuyoshi Nakada
623058649e
[DOC] Add Argument args subsection 2024-01-24 12:44:40 +09:00
Nobuyoshi Nakada
be6e06ef74
[DOC] Separate standard shells per platforms 2024-01-24 12:44:40 +09:00
Nobuyoshi Nakada
828f3ecfcd
[DOC] Move exe_path example to Process module document
Exchanged with `Kernel.spawn`, like as `Kernel.exec` and
`Kernel.system`.  This description should be common for these methods.
2024-01-24 12:44:39 +09:00
Burdette Lamar
df5f2fab93
[DOC] Correction for Process.spawn doc 2024-01-24 12:43:52 +09:00
dependabot[bot]
c16aaf119a Bump actions/upload-artifact from 4.2.0 to 4.3.0
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.2.0 to 4.3.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](694cdabd8b...26f96dfa69)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-23 19:10:16 -08:00
Hiroshi SHIBATA
a170f1859b
No longer needed to sync syslog 2024-01-24 10:44:18 +09:00
Hiroshi SHIBATA
d914f82a3c
Use test fixed version of debug gem https://github.com/ruby/debug/pull/1067 2024-01-24 09:53:41 +09:00
Alan Wu
974b141ffe YJIT: Reuse get_array_{ptr,len} 2024-01-23 19:47:26 -05:00
Alan Wu
ac1e9e443a YJIT: Fix ruby2_keywords splat+rest and drop bogus checks
YJIT didn't guard for ruby2_keywords hash in case of splat calls that
land in methods with a rest parameter, creating incorrect results.

The compile-time checks didn't correspond to any actual effects of
ruby2_keywords, so it was masking this bug and YJIT was needlessly
refusing to compile some code. About 16% of fallback reasons in
`lobsters` was due to the ISeq check.

We already handle the tagging part with
exit_if_supplying_kw_and_has_no_kw() and should now have a dynamic guard
for all splat cases.

Note for backporting: You also need 7f51959ff1.

[Bug #20195]
2024-01-23 19:22:57 -05:00
Takashi Kokubun
c0cabc0a69
Dump annotations on RubyVM::ISeq.disasm (#9667)
Make it easier to check what annotations an ISEQ has. SINGLE_NOARG_LEAF
is added automatically, so it's hard to be sure about the annotation by
just reading code. It's also unclear to me what happens to it with
Primitive.mandatory_only?, but this at least explains that LEAF
annotation is not added to the non-mandatory_only ISEQ.
2024-01-23 22:54:39 +00:00
Peter Zhu
909a710a69 [PRISM] Fix anonymous splat nodes
Fixes ruby/prism#2257.
2024-01-23 17:45:51 -05:00
Takashi Kokubun
996776e936 Leave a comment about the limitation of Primitive
and adjust some code styling from that PR.
2024-01-23 14:39:37 -08:00
Peter Zhu
7ac74f5c77 Revert "Skip a failing test for Prism"
This reverts commit 557b69e83b27dafea435719fc3afc2e67e155962.
2024-01-23 15:23:48 -05:00
Peter Zhu
cecf42601a [PRISM] Fix block fowarding 2024-01-23 15:23:13 -05:00
Peter Zhu
333f4b4930 [PRISM] Support block parameters with no name
Fixes ruby/prism#2249.
2024-01-23 15:23:13 -05:00
Takashi Kokubun
c84237f953
Rewrite Array#each in Ruby using Primitive (#9533) 2024-01-23 20:09:57 +00:00
Takashi Kokubun
27c1dd8634
YJIT: Allow inlining ISEQ calls with a block (#9622)
* YJIT: Allow inlining ISEQ calls with a block

* Leave a TODO comment about u16 inline_block
2024-01-23 19:36:23 +00:00
Takashi Kokubun
557b69e83b Skip a failing test for Prism
This should be reverted once https://github.com/ruby/prism/issues/2249
is closed.
2024-01-23 11:00:05 -08:00
Jean Boussier
a846d391d3 List branch maintainers in maintainers.md
I'm not aware of this information being available
anywhere else.
2024-01-23 18:02:42 +01:00
Alan Wu
7f51959ff1 YJIT: Move guard up for a case of splat+rest
Previously, YJIT put the guard for having enough items to extract from
splat array at a place where the side exit is invalid, so if the guard
fails, YJIT could raise something other than ArgumentError. Move the
guard up to a place before any stack manipulation.

[Bug #20204]
2024-01-23 11:04:16 -05:00
Peter Zhu
b14674b236 Memory leak with TracePoint on bmethod
[Bug #20194]

When disabling the TracePoint on bmethod, the hooks list is not freed.

For example:

    obj = Object.new
    obj.define_singleton_method(:foo) {}
    bmethod = obj.method(:foo)
    tp = TracePoint.new(:return) {}

    10.times do
      100_000.times do
        tp.enable(target: bmethod) {}
      end

      puts `ps -o rss= -p #{$$}`
    end

Before:

    18208
    22832
    26528
    29728
    34000
    37776
    40864
    44400
    47680
    51504

After:

    16688
    17168
    17168
    17248
    17696
    17760
    17824
    17824
    17856
    17920
2024-01-23 10:47:04 -05:00
Hiroshi SHIBATA
7cf74a2ff2 Run test-bundled-gems again with macos-arm-oss runner 2024-01-23 16:10:58 +09:00
Hiroshi SHIBATA
5987f0b7c8 Retired macos-11 because this version is EOL, and added macos-13(beta) 2024-01-23 16:10:58 +09:00
Aaron Patterson
8c3eb47fff All btests are passing with Prism
We can remove the exclusion list now
2024-01-22 16:35:58 -08:00
Aaron Patterson
cfa15bb173 Handle trailing commas on blocks
We need to set a special flag on block iseqs when there is a trailing
comma.

Fixes: https://github.com/ruby/prism/issues/2244
2024-01-22 16:35:58 -08:00
dependabot[bot]
6fb9dc5089 [rubygems/rubygems] Bump shlex
Bumps [shlex](https://github.com/comex/rust-shlex) from 1.1.0 to 1.3.0.
- [Changelog](https://github.com/comex/rust-shlex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/comex/rust-shlex/commits)

---
updated-dependencies:
- dependency-name: shlex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

https://github.com/rubygems/rubygems/commit/ca4efb9e9d
2024-01-23 00:33:48 +00:00
dependabot[bot]
cb8235c9c9 [rubygems/rubygems] Bump rb-sys
Bumps [rb-sys](https://github.com/oxidize-rb/rb-sys) from 0.9.86 to 0.9.87.
- [Release notes](https://github.com/oxidize-rb/rb-sys/releases)
- [Commits](https://github.com/oxidize-rb/rb-sys/compare/v0.9.86...v0.9.87)

---
updated-dependencies:
- dependency-name: rb-sys
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

https://github.com/rubygems/rubygems/commit/40292944e8
2024-01-23 00:33:39 +00:00
dependabot[bot]
7811dd169b [rubygems/rubygems] Bump shlex
Bumps [shlex](https://github.com/comex/rust-shlex) from 1.1.0 to 1.3.0.
- [Changelog](https://github.com/comex/rust-shlex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/comex/rust-shlex/commits)

---
updated-dependencies:
- dependency-name: shlex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

https://github.com/rubygems/rubygems/commit/70812aeeb1
2024-01-23 00:33:28 +00:00
Aaron Patterson
f423ced5ab update tests 2024-01-22 16:02:41 -08:00
Aaron Patterson
270a46e392 Check keyword parameters correctly
We weren't checking the right offsets when compiling methods with
keyword parameters that had complex code.

Fixes: https://github.com/ruby/prism/issues/2228
2024-01-22 16:02:41 -08:00
yui-knk
ee7f63ebba Make lastline and nextline to be rb_parser_string
This commit changes `struct parser_params` lastline and nextline
from `VALUE` (String object) to `rb_parser_string_t *` so that
dependency on Ruby Object is reduced.
`parser_string_buffer_t string_buffer` is added to `struct parser_params`
to manage `rb_parser_string_t` pointers of each line. All allocated line
strings are freed in `rb_ruby_parser_free`.
2024-01-23 08:58:16 +09:00
Hiroshi SHIBATA
706eea9d3c
Fixup 2e69137dbe9fd7c03dac9b8adc30a7eba3ecb10b 2024-01-23 08:45:45 +09:00
Matt Valentine-House
d8af85ad14 [Prism] Uncomment tests that now pass 2024-01-22 15:15:32 -08:00
Matt Valentine-House
d054904cad [Prism] Don't change file after setting it.
This causes the Iseq file names to be wrong, which is affecting
Tracepoint events in certain cases.

because we're taking a pointer to the string and using it in
`pm_string_mapped_pointer` we also need to `RB_GC_GUARD` the relevant
Ruby object to ensure it's not moved or swept before the parser has been
free'd.
2024-01-22 15:15:32 -08:00
Matt Valentine-House
4592fdc545 [Prism] path and script name are not the same
When loading Ruby from a file, or parsing using
RubyVM::InstructionSequence.
2024-01-22 15:15:32 -08:00
dependabot[bot]
2e2dfc4623 Bump ruby/setup-ruby from 1.168.0 to 1.169.0
Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.168.0 to 1.169.0.
- [Release notes](https://github.com/ruby/setup-ruby/releases)
- [Commits](https://github.com/ruby/setup-ruby/compare/v1.168.0...5daca165445f0ae10478593083f72ca2625e241d)

---
updated-dependencies:
- dependency-name: ruby/setup-ruby
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-22 15:12:23 -08:00
Peter Zhu
708fa77404 [PRISM] Fix keyword arguments in IndexOrWriteNode
Fixes ruby/prism#2236.
2024-01-22 15:07:52 -08:00
Peter Zhu
1838dbf6e7 [PRISM] Fix splat and block in aset 2024-01-22 15:07:39 -08:00
Peter Zhu
1847192366 [PRISM] Fix block in aset
Fixes ruby/prism#2223.
2024-01-22 15:07:39 -08:00
dependabot[bot]
a64e26c5d5
Bump capstone from 0.10.0 to 0.11.0 in /yjit (#9653)
Bumps [capstone](https://github.com/capstone-rust/capstone-rs) from 0.10.0 to 0.11.0.
- [Release notes](https://github.com/capstone-rust/capstone-rs/releases)
- [Changelog](https://github.com/capstone-rust/capstone-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/capstone-rust/capstone-rs/compare/capstone-v0.10.0...capstone-v0.11.0)

---
updated-dependencies:
- dependency-name: capstone
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-01-22 14:44:00 -08:00
Takashi Kokubun
28fc7fa852 Revert "Bump shlex"
This reverts commit dcabe87fc8b8523cabea533df18d2b3b616e78da.

Revert "Bump shlex"

This reverts commit 47264b78c2e1be441d043a404f8b0d0bf7d8f62b.

Avoid diversion in gem sync. They should be managed in rubygems/rubygems
and then sync-ed to ruby/ruby.
2024-01-22 14:35:16 -08:00
Takashi Kokubun
cffa54acad Try to exclude rubygems Rust stuff from dependabot
It should be managed in rubygems/rubygems and sync-ed to ruby/ruby. We
shouldn't get PRs to rubygems in ruby/ruby.
2024-01-22 14:34:29 -08:00
dependabot[bot]
dcabe87fc8 Bump shlex
Bumps [shlex](https://github.com/comex/rust-shlex) from 1.1.0 to 1.3.0.
- [Changelog](https://github.com/comex/rust-shlex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/comex/rust-shlex/commits)

---
updated-dependencies:
- dependency-name: shlex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-22 14:16:10 -08:00
dependabot[bot]
bd1895990c
Bump shlex from 1.1.0 to 1.3.0 in /yjit/bindgen (#9652)
Bumps [shlex](https://github.com/comex/rust-shlex) from 1.1.0 to 1.3.0.
- [Changelog](https://github.com/comex/rust-shlex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/comex/rust-shlex/commits)

---
updated-dependencies:
- dependency-name: shlex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-01-22 14:11:07 -08:00
dependabot[bot]
47264b78c2 Bump shlex
Bumps [shlex](https://github.com/comex/rust-shlex) from 1.1.0 to 1.3.0.
- [Changelog](https://github.com/comex/rust-shlex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/comex/rust-shlex/commits)

---
updated-dependencies:
- dependency-name: shlex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-22 14:10:39 -08:00
Peter Zhu
8065672d99 [PRISM] Force semicolon at the end of PM macros 2024-01-22 15:22:12 -05:00