| Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Implements [Feature #19000]
This commit adds copy with changes functionality for `Data` objects
using a new method `Data#with`.
Since Data objects are immutable, the only way to change them is by
creating a copy. This PR adds a `with` method for `Data` class instances
that optionally takes keyword arguments.
If the `with` method is called with no arguments, the behaviour is the
same as the `Kernel#dup` method, i.e. a new shallow copy is created
with no field values changed.
However, if keyword arguments are supplied to the `with` method, then
the copy is created with the specified field values changed. For
example:
```ruby
Point = Data.define(:x, :y)
point = Point.new(x: 1, y: 2)
point.with(x: 3) # => #<data Point x: 3, y: 2>
```
Passing positional arguments to `with` or passing keyword arguments to
it that do not correspond to any of the members of the Data class will
raise an `ArgumentError`.
Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
Notes:
Merged-By: k0kubun <takashikkbn@gmail.com>
|
|
cf0b413ef8b794ef6e7436f22fd5a998050dada9
|
|
|
|
https://github.com/ruby/net-http/commit/71bae5c0fe
|
|
https://github.com/ruby/net-http/commit/e4df80f299
|
|
https://github.com/ruby/net-http/commit/df5a554fa8
|
|
* Set up RBS_SKIP_TESTS
Notes:
Merged-By: soutaro <matsumoto@soutaro.com>
|
|
|
|
Surrounding with brackets is just a convention for the bugs tracker
links.
|
|
|
|
Inconsistency pointed out by @mame:
```
>> Enumerator.product([1], [2], [3]).to_a
=> [[1, 2, 3]]
>> Enumerator.product([1], [2]).to_a
=> [[1, 2]]
>> Enumerator.product([1]).to_a
=> [1]
>> Enumerator.product().to_a
=> [nil]
```
Got fixed as follows:
```
>> Enumerator.product([1], [2], [3]).to_a
=> [[1, 2, 3]]
>> Enumerator.product([1], [2]).to_a
=> [[1, 2]]
>> Enumerator.product([1]).to_a
=> [[1]]
>> Enumerator.product().to_a
=> [[]]
```
This was due to the nature of the N-argument funcall in Ruby.
|
|
|
|
|
|
|
|
|
|
Subtract max value from offset when sign bit is set, without string operations.
Notes:
Merged-By: k0kubun <takashikkbn@gmail.com>
|
|
https://github.com/ruby/optparse/commit/766f567405
|
|
Make the WASI_SDK_PATH variable mandatory when building for wasi host.
This requirement prevents developers from being stuck due to unfriendly
configuration's error message.
Notes:
Merged: https://github.com/ruby/ruby/pull/5464
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/6975
|
|
`ruby` is not always available in certain build environments and
configure options. Choose appropriate command line using EnvUtil.
Notes:
Merged: https://github.com/ruby/ruby/pull/5417
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/6973
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/6974
|
|
* Especially around Enumerator.
Notes:
Merged: https://github.com/ruby/ruby/pull/6974
|
|
|
|
RDoc was making every usage of the word "GC" link to the page for GC
(which is the same page).
|
|
RDoc parses the last arrow in the call-seq as the arrow for the return
type. It was getting confused over the arrow in the hash.
|
|
|
|
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/6972
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/6972
|
|
* See https://bugs.ruby-lang.org/issues/19078#note-30
Notes:
Merged: https://github.com/ruby/ruby/pull/6972
|
|
Ref: [Feature #19245]
At the very least this behavior should be documented.
Notes:
Merged: https://github.com/ruby/ruby/pull/6969
|
|
|
|
https://github.com/ruby/irb/commit/a8ea9963c6
|
|
(https://github.com/ruby/irb/pull/481)
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
|
|
If a size pooll is small, then `min_free_slots < heap_init_slots` is true.
This means that min_free_slots will be set to heap_init_slots. This
causes `swept_slots < min_free_slots` to be true in a later if statement.
The if statement could trigger a major GC which could cause major GC
thrashing.
Notes:
Merged: https://github.com/ruby/ruby/pull/6971
|
|
When out-of-place build, and revision.h does not exist in the source
directory, `VPATH` fallbacks to the current directory.
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/6968
|
|
|
|
|
|
|
|
|