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

81867 Коммитов

Автор SHA1 Сообщение Дата
Jemma Issroff b9dfe04a73 [PRISM] Implementing forwarding of args for ForwardingSuperNode
ForwardingSuperNodes need to actually forward any applicable
arguments. This commit implements that logic, by using the data
stored on the local iseq about the parameters to forward the
appropriate arguments.
2023-12-12 13:45:21 -05:00
Jemma Issroff 68753e4408 [PRISM] Allow rest parameter to be `*`
Prior to this commit, if a rest parameters was `*`, we did not add
it to the locals table correctly. This commit fixes that.
2023-12-12 13:45:21 -05:00
Kevin Newton f61df27b4c [ruby/prism] Use new flag setters for attribute write
https://github.com/ruby/prism/commit/1e07832778
2023-12-12 18:43:59 +00:00
Kouhei Yanagita 06e2fbb826 [Bug #19114] Fix for multiple calls of TracePoint#enable 2023-12-12 09:36:37 -08:00
Ufuk Kayserilioglu 1f22245ed5 [ruby/prism] Start using flag macros/methods exclusively
https://github.com/ruby/prism/commit/5f05a6fe83
2023-12-12 17:35:53 +00:00
Ufuk Kayserilioglu bdb38dd9f2 [ruby/prism] Add methods for setting/unsetting and macros for testing a flags
https://github.com/ruby/prism/commit/e5f37d1407
2023-12-12 17:35:52 +00:00
David Rodríguez 67940b135c [rubygems/rubygems] Bump rake version used by tests
And make it easier to update next time.

https://github.com/rubygems/rubygems/commit/1ea4bfa5d8
2023-12-12 17:16:19 +00:00
Kevin Newton 278ce27ee4 [ruby/prism] Flag for attribute write on calls
https://github.com/ruby/prism/commit/465731969c
2023-12-12 15:55:54 +00:00
Jeremy Evans 2f1d6da8c4
Fix op asgn calls with keywords
Examples of such calls:

```ruby
obj[kw: 1] += fo
obj[**kw] &&= bar
```

Before this patch, literal keywords would segfault in the compiler,
and keyword splat usage would result in TypeError.

This handles all cases I can think of:

* literal keywords
* keyword splats
* combined with positional arguments
* combined with regular splats
* both with and without blocks
* both popped and non-popped cases

This also makes sure that to_hash is only called once on the keyword
splat argument, instead of twice, and make sure it is called before
calling to_proc on a passed block.

Fixes [Bug #20051]

Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
2023-12-12 07:34:53 -08:00
Martin Emde f671c5d179 [rubygems/rubygems] Make RubyDsl a little easier to read; avoid a Hash sometimes
https://github.com/rubygems/rubygems/commit/2dca83722b
2023-12-12 15:26:01 +00:00
Nobuyoshi Nakada f466afa176
[PRISM] Do not hide syntactically required parentheses within macros
It makes code formatters confused when auto indenting.
2023-12-12 23:57:27 +09:00
Peter Zhu 185b7e92a3 Make WeakKeyMap safe for compaction during allocation
During allocation, the table may not have been allocated yet which would
crash in the st_foreach.
2023-12-12 09:01:21 -05:00
Peter Zhu 33cf8f640b Make WeakMap safe for compaction during allocation
During allocation, the table may not have been allocated yet which would
crash in the st_foreach.
2023-12-12 09:01:21 -05:00
Ufuk Kayserilioglu d313c82f79 [ruby/prism] Update tests and snapshots
https://github.com/ruby/prism/commit/0663e2bcfa
2023-12-12 13:05:09 +00:00
Ufuk Kayserilioglu 43229d531f [ruby/prism] Start `KeywordHashNode`s with `STATIC_KEYS` set, until hit an element that should clear it
https://github.com/ruby/prism/commit/7c7c486507
2023-12-12 13:05:09 +00:00
Ufuk Kayserilioglu 25b9a0cbc8 [ruby/prism] Add `STATIC_KEYS` flag for `KeywordHashNode`
https://github.com/ruby/prism/commit/aa83de39c1
2023-12-12 13:05:08 +00:00
Martin Emde d1c25605f6 [rubygems/rubygems] Resolve `ruby file: ".ruby-version"` relative to Gemfile
https://github.com/rubygems/rubygems/commit/0cbbaed8a5
2023-12-12 12:40:17 +00:00
Stan Lo 28a9a4275c [ruby/irb] Remove trailing space
This is required to fix ruby/ruby's CI

https://github.com/ruby/irb/commit/3c77213209
2023-12-12 11:27:39 +00:00
Burdette Lamar 35990cb38c [ruby/irb] [DOC] RDoc for module IRB
(https://github.com/ruby/irb/pull/738)

[DOC] RDoc for module IRB

https://github.com/ruby/irb/commit/f3a0626298
2023-12-12 10:34:38 +00:00
KJ Tsanaktsidis 25711e7063 Partially revert "Set AI_ADDRCONFIG when making getaddrinfo(3) calls"
This _partially_ reverts commit
d2ba8ea54a, but for UDP sockets only.

With TCP sockets (and other things which use `rsock_init_inetsock`), the
order of operations is to call `getaddrinfo(3)` with AF_UNSPEC, look at
the returned addresses, pick one, and then call `socket(2)` with the
family for that address (i.e. AF_INET or AF_INET6).

With UDP sockets, however, this is reversed; `UDPSocket.new` takes an
address family as an argument, and then calls `socket(2)` with that
family. A subsequent call to UDPSocket#connect will then call
`getaddrinfo(3)` with that family.

The problem here is that...

* If you are in a networking situation that _only_ has loopback addrs,
* And you want to look up a name like "localhost" (or NULL)
* And you pass AF_INET or AF_INET6 as the ai_family argument to
  getaddrinfo(3),
* And you pass AI_ADDRCONFIG to the hints argument as well,

then glibc on Linux will not return an address. This is because
AI_ADDRCONFIG is supposed to return addresses for families we actually
have an address for and could conceivably connect to, but also is
documented to explicitly ignore localhost in that situation.

It honestly doesn't make a ton of sense to pass AI_ADDRCONFIG if you're
explicitly passing the address family anyway, because you're not looking
for "an address for this name we can connect to"; you're looking for "an
IPv(4|6) address for this name". And the original glibc bug that
d2ba8ea5 was supposed to work around was related to parallel issuance of
A and AAAA queries, which of course won't happen if an address family is
explicitly specified.

So, we fix this by not passing AI_ADDRCONFIG for calls to
`rsock_addrinfo` that we also pass an explicit family to (i.e. for
UDPsocket).

[Bug #20048]
2023-12-12 20:05:21 +11:00
git f64485af7e Update bundled gems list as of 2023-12-12 2023-12-12 06:58:23 +00:00
Nobuyoshi Nakada e411bd5b36 [ruby/securerandom] [DOC] Satisfy RDoc coverage
https://github.com/ruby/securerandom/commit/ddf2672e47
2023-12-12 06:40:44 +00:00
Nobuyoshi Nakada dbd704ae6f [ruby/securerandom] [DOC] Add documents of methods and constants
https://github.com/ruby/securerandom/commit/9a99978135
2023-12-12 06:40:43 +00:00
Yusuke Endoh cb93d10ae5 [ruby/securerandom] [DOC] Improve the document about reproducibility of uuid_v7
https://github.com/ruby/securerandom/pull/19/files#r1329476195

https://github.com/ruby/securerandom/commit/156cbb8448
2023-12-12 06:36:10 +00:00
Jeremy Evans f49af3c969 Make Dir#chdir never yield args, and return block return value
If no block is given, return 0 instead of nil for consistency
with Dir.chdir and Dir.fchdir.
2023-12-11 22:31:16 -08:00
Takashi Kokubun 9f0065a077
Initialize interrupt queue before signal handlers (#9196) 2023-12-11 21:12:08 -08:00
Martin Emde 1e5c8afb15 [rubygems/rubygems] Ensure that the lockfile mtime is not altered on frozen install
https://github.com/rubygems/rubygems/commit/6847709ee0
2023-12-12 02:39:57 +00:00
NARUSE, Yui 6b3abcf462 fix regexp pattern of diff 2023-12-12 11:22:40 +09:00
Samuel Giddins e223dde329 [rubygems/rubygems] Allow bundle pristine to run in parallel
Also fix running when BUNDLE_NO_INSTALL happens to be set, same as with install/update commands

https://github.com/rubygems/rubygems/commit/a555fd6ccd
2023-12-12 02:10:53 +00:00
Nobuyoshi Nakada 305f66b859
Save $VERBOSE properly 2023-12-12 11:06:27 +09:00
Yusuke Endoh 73b43fffa1 Prevent a warning: assigned but unused variable - status 2023-12-12 10:31:37 +09:00
Yusuke Endoh 207dcf07e1 Prevent a warning: method redefined 2023-12-12 10:31:37 +09:00
Yusuke Endoh cfb8494d54 Prevent warning: possibly useless use of a literal in void context 2023-12-12 10:31:37 +09:00
Yusuke Endoh 0c287df3bc Prevent a warning: setting Encoding.default_external 2023-12-12 10:31:37 +09:00
Yusuke Endoh 535eb4de11 Remove unused statement
... to disable a warning: assigned but unused variable - expected
2023-12-12 10:31:37 +09:00
Franz Liedke 6414f260fc [rubygems/rubygems] Refactor: Wrap filesystem access
https://github.com/rubygems/rubygems/commit/119d4bdc09
2023-12-12 01:08:20 +00:00
Franz Liedke 0653fb026c [rubygems/rubygems] Refactor: Move filesystem access into Definition class
https://github.com/rubygems/rubygems/commit/2720da2659
2023-12-12 01:08:20 +00:00
Franz Liedke 0ec88b54f3 [rubygems/rubygems] bundle lock: Always touch the lockfile
https://github.com/rubygems/rubygems/commit/fd2e71dfdb
2023-12-12 01:08:19 +00:00
David Rodríguez 8c2480c9ed
Unlock tilt since we no longer support Ruby 2.6 2023-12-12 10:04:57 +09:00
David Rodríguez a848c070d2
[rubygems/rubygems] Remove doc not adding much value
https://github.com/rubygems/rubygems/commit/c241a88962
2023-12-12 10:04:57 +09:00
Martin Emde 0e05392dcc
[rubygems/rubygems] Make tests compatible with paths that contain a + char
https://github.com/rubygems/rubygems/commit/3355c80c90
2023-12-12 10:04:57 +09:00
Martin Emde 3b9ea6648f
[rubygems/rubygems] Use StringIO 3.1.0 in tests to work with ruby 3.3.0
https://github.com/rubygems/rubygems/commit/8a936d733d
2023-12-12 10:04:57 +09:00
David Rodríguez 0b24c71a5a
[rubygems/rubygems] Improve enabling bundled gems warnings
https://github.com/rubygems/rubygems/commit/7be5b40ca9
2023-12-12 10:04:57 +09:00
David Rodríguez a06bf001b2
[rubygems/rubygems] Remove non-transparent requirement added to prerelease gems
I think we can safely assume these days that all RubyGems and Bundler
versions that will ever bundle a new gem created in 2023 support
prereleases.

So this non transparent requirement is not necessary.

In my opinion, it should be the gem author to explicitly add this
constraint, not RubyGems.

https://github.com/rubygems/rubygems/commit/b165e6d725
2023-12-12 10:04:57 +09:00
Vít Ondruch b37288c047
[rubygems/rubygems] Make the "auto-user-install" logic easier to follow
https://github.com/rubygems/rubygems/commit/4b4d9c0106
2023-12-12 10:04:56 +09:00
David Rodríguez c032dfb5cb
[rubygems/rubygems] Fix installing from source when same bundler version already a default gem
https://github.com/rubygems/rubygems/commit/620119308e
2023-12-12 10:04:56 +09:00
David Rodríguez 23289ad45b
[rubygems/rubygems] Extract some common strings to variables
https://github.com/rubygems/rubygems/commit/48bc573310
2023-12-12 10:04:56 +09:00
David Rodríguez a811ebf3d5
[rubygems/rubygems] Revert missing extensions patch
https://github.com/rubygems/rubygems/commit/4016c6c024
2023-12-12 10:04:56 +09:00
Nobuyoshi Nakada 38348502b5
[DOC] Update description about shared library suffix
Loading an extension library with ".dll" suffix on Windows was very
old behavior, and the suffix must be ".so" since 2004.  See commits
removing DLEXT2 181a3a2af5 and
b76ad15ed0.

Instead, use macOS as an example, which uses ".bundle".
2023-12-12 09:39:13 +09:00
Alan Wu 4eca329d29 Skip a YJIT test on RJIT 2023-12-11 19:21:08 -05:00