Project

General

Profile

Activity

From 09/10/2023 to 09/16/2023

09/16/2023

10:27 PM Revision cd67c0d2 (git): [ruby/irb] Test should not depend on user's irbrc file
(https://github.com/ruby/irb/pull/714)
https://github.com/ruby/irb/commit/02703c46f9
tompng (tomoya ishida)
06:29 PM Revision 380b42fe (git): Fix comment for rb_enc_str_new [ci skip]
jhawthorn (John Hawthorn)
05:24 PM Revision 4aac7b1a (git): Another try to fix build in emscripten
malloc_trim is defined in emscripten/emmalloc.h on emscripten. peterzhu2118 (Peter Zhu)
03:47 PM Bug #19683: ruby-3.3.0-preview1 does not build with BSD make without --with-baseruby
This is still a problem in 3.3.0-preview2. I've been using the following bad hack to work around it:
```diff
Index: common.mk
--- common.mk.orig
+++ common.mk
@@ -378,10 +378,10 @@ ext/configure-ext.mk: $(PREP) all-incs $(MKFILES...
jeremyevans0 (Jeremy Evans)
03:02 PM Bug #19864 (Closed): Ruby 3.2 Changed Behavior With One Sided Ranges
Applied in changeset commit:git|25711683e86271385e8abe09a9c03782000e48db.
----------
Fix regression when testing inclusion in unbounded ranges
Caused by 04a92a6764bf678919cf4b68a27496a39d6b886a. This treats
unbounded ranges of arbitra...
jeremyevans (Jeremy Evans)
05:53 AM Bug #19864: Ruby 3.2 Changed Behavior With One Sided Ranges
I've submitted a pull request for the diff posted earlier (with tests): https://github.com/ruby/ruby/pull/8458 jeremyevans0 (Jeremy Evans)
03:02 PM Revision 25711683 (git): Fix regression when testing inclusion in unbounded ranges
Caused by 04a92a6764bf678919cf4b68a27496a39d6b886a. This treats
unbounded ranges of arbitrary objects the same as how unbounded
string ranges are treated:
(..x) === y # (y <=> x) <= 0
(...x) === y # (y <=> x) < 0
(x..) === y...
jeremyevans (Jeremy Evans)
02:15 PM Feature #19744: Namespace on read
It seems interesting.
Regarding the motivation I wanted to mention some alternatives.
> Running multiple applications on a Ruby process
> ...
These 3 motivations can actually be solved today on TruffleRuby and I think on JRuby as well b...
Eregon (Benoit Daloze)
01:36 PM Revision 8835ca23 (git): [ruby/yarp] Fix a possible null pointer deference
https://github.com/ruby/yarp/commit/41f601b81b Haldun Bayhantopcu
01:13 PM Revision e779465f (git): Add comment markers in empty lines [ci skip]
nobu (Nobuyoshi Nakada)
01:13 PM Revision e6ce4903 (git): Align comments [ci skip]
nobu (Nobuyoshi Nakada)
01:08 PM Revision 209d5f84 (git): Fix malloc_trim on emscripten
```
gc.c:9746:5: error: implicit declaration of function 'malloc_trim' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
malloc_trim(0);
^
```
http://rubyci.s3.amazonaws.com/crossruby/crossruby-master-wasm32_emscripten...
peterzhu2118 (Peter Zhu)
12:48 PM Revision a8afedce (git): [ruby/irb] Handle Concurrent Sessions and Saving Readline::HISTORY
(https://github.com/ruby/irb/pull/651)
* handle concurrent sessions and saving Readline::HISTORY, fixes https://github.com/ruby/irb/pull/510
* separate tests
* don't mutate the HISTORY object on the class
* avoid repeated .to_i calls...
Chad Schroeder
12:47 PM Bug #19880: Missing write barrier in iseq instruction list
Merged into ruby_3_2 at https://github.com/ruby/ruby/commit/a7335e11e354d1ee2e15233f32f087230069ad5c. nagachika (Tomoyuki Chikanaga)
08:24 AM Revision b4213a73 (git): [Feature #19839] Fix `Range#overlap?` for empty ranges
Empty ranges do not overlap with any range.
Regarding benchmarks, PR#8242 is significantly faster in some cases,
but one of these two cases is a wrong result.
| |ActiveSupport| PR#8242|built-ruby|
|:----------...
nobu (Nobuyoshi Nakada)
08:07 AM Feature #19839: Need a method to check if two ranges overlap
@nobu is trying to fix the corner cases that @ko1 pointed: https://github.com/ruby/ruby/pull/8448 mame (Yusuke Endoh)
05:57 AM Feature #19839 (Closed): Need a method to check if two ranges overlap
Applied in changeset commit:git|e9b503f1bb9692eda1d1f55f62c19d861b88a0d5.
----------
[Feature #19839] Add Range#overlap?
Add a method that returns true if two range overlap, otherwise false.
```
(0..10).overlap?(5..15) #=> true
(0..10...
shouichi (Shouichi Kamiya)
07:52 AM Revision c3ef7a52 (git): Fix malloc_trim() on wasm32
```
compiling gc.c
gc.c:9746:5: error: implicit declaration of function 'malloc_trim' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
malloc_trim(0);
^
1 error generated.
```
byroot (Jean Boussier)
06:54 AM Misc #19883: DevMeeting-2023-10-12
* [Feature #19744] Namespace on read (tagomoris)
* Now the PoC implementation works, can require 2 different versions of native extension libraries.
* I will introduce the motivation and the implementation idea.
* I need discuss...
tagomoris (Satoshi Tagomori)
06:20 AM Bug #19886 (Closed): "default->bundled gem" warning is not shown under "bundle exec"
```
$ cat Gemfile
source "https://rubygems.org"
$ cat test.rb
require "base64"
$ bundle exec ruby test.rb
$
```
In this situation, `bundle exec ruby test.rb` should print a warning: base64 which will be not part of the de...
mame (Yusuke Endoh)
05:57 AM Revision e9b503f1 (git): [Feature #19839] Add Range#overlap?
Add a method that returns true if two range overlap, otherwise false.
```
(0..10).overlap?(5..15) #=> true
(0..10).overlap?(20..30) #=> false
```
shouichi (Shouichi Kamiya)
05:17 AM Revision a7335e11 (git): [Backport 3.2] Fix missing write barrier in iseq instruction list (#8431)
Fix missing write barrier in iseq instruction list
[Bug #19880]
There's a missing write barrier for operands in the iseq instruction
list, which can cause crashes.
It can be reproduced when Ruby is compiled with `-DRUBY_DEBUG_ENV=1`.
...
peterzhu2118 (Peter Zhu)
04:10 AM Bug #19885 (Assigned): Invalid Warning for Default Gems That Will Move to Bundled Gems
Agreed. I think the warning is good only when bundler is used.
@hsbt How about https://github.com/ruby/ruby/pull/8457 ?
mame (Yusuke Endoh)
04:06 AM Revision e159971e (git): [For ruby_3_2] Fix unused_mut Rust warnings (#8435)
Fix unused_mut Rust warnings
Rust version 1.71.0 and up issue these warnings. On GitHub CI, the
warnings were previously seen in -DYJIT_FORCE_ENABLE runs.
alanwu (Alan Wu)
03:10 AM Revision 7d08dbd0 (git): Optimize Range#bsearch for beginless/endless ranges
On Range#bsearch for endless ranges, we try positions at `begin + 2**i` (i = 0, 1, 2, ...)
to find a point that satisfies a given condition.
Subsequently, we perform binary searching with the interval `[begin, begin + 2**n]`.
However, t...
kyanagi (Kouhei Yanagita)
03:00 AM Revision 67dedf8c (git): Ignore changed files under removed paths
This fixes the issue commit 43ab2acf8242c580b1ef5d644ea94d48669d4869
"Resurrect gem-specific patterns for sync" described.
nobu (Nobuyoshi Nakada)
01:41 AM Revision 9aeb6e72 (git): YJIT: Avoid creating a vector in get_temp_regs() (#8446)
* YJIT: Avoid creating a vector in get_temp_regs()
Co-authored-by: Alan Wu <alansi.xingwu@shopify.com>
* Remove unused import
---------
Co-authored-by: Alan Wu <alansi.xingwu@shopify.com>
Co-authored-by: Alan Wu <XrXr@users.noreply.g...
k0kubun (Takashi Kokubun)
12:34 AM Revision 1fbfd066 (git): Update default gems list at 7f96c9be9e998adb0f9db751bf9cd6 [ci skip]
git[bot]
12:32 AM Revision 7f96c9be (git): [ruby/yarp] Bump to version 0.12.0
https://github.com/ruby/yarp/commit/c71137377f kddnewton (Kevin Newton)

09/15/2023

11:54 PM Revision 43ab2acf (git): Resurrect gem-specific patterns for sync
Yet another partial revert of https://github.com/ruby/ruby/pull/8329,
similar to 00f263e6c4.
Repro: On ruby/ruby@1be64e34d0, `tool/sync_default_gems.rb yarp
162c2088eec6ec8f0558559e082cd661c18ee02a` should exist successfully, but
it doe...
k0kubun (Takashi Kokubun)
11:32 PM Revision cb686b9c (git): [ruby/yarp] Handle missing clauses in case statement
https://github.com/ruby/yarp/commit/1ad7fba5ef kddnewton (Kevin Newton)
11:21 PM Revision 4c28a61e (git): [ruby/yarp] Ensure multi targets are only in valid locations
https://github.com/ruby/yarp/commit/8bffb8a762 kddnewton (Kevin Newton)
11:08 PM Revision 8db3e3c3 (git): [ruby/yarp] require constant pool capacity to be a power of 2
https://github.com/ruby/yarp/commit/dea8d3f29f froydnj (Nathan Froyd)
11:03 PM Revision 7cec7d14 (git): YJIT: Fix object movement bug in iseq guard for invokeblock
Since the compile-time iseq used in the guard was not marked and updated
during compaction, a runtime value reusing the address could falsely pass
the guard.
Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com>
alanwu (Alan Wu)
10:59 PM Revision 1be64e34 (git): [ruby/yarp] Alnum cannot be %-literal delimiters
https://github.com/ruby/yarp/commit/4ba6d5ca70 kddnewton (Kevin Newton)
10:38 PM Revision 18780c22 (git): [ruby/yarp] Properly handle invalid underscores in number literals
https://github.com/ruby/yarp/commit/35da3d1a4c kddnewton (Kevin Newton)
10:36 PM Revision b848700c (git): [ruby/yarp] Extract test listener to its own class
https://github.com/ruby/yarp/commit/c8caa997c0 kddnewton (Kevin Newton)
10:36 PM Revision 35960ce6 (git): [ruby/yarp] Add node event dispatcher
This commit changes the node template to create a dispatcher class,
which can be used to walk an AST an emit events to all registered
listeners
https://github.com/ruby/yarp/commit/03a45f85e6
Co-authored-by: Kevin Newton <kddnewton@user...
Vinicius Stock
10:26 PM Bug #19885 (Closed): Invalid Warning for Default Gems That Will Move to Bundled Gems
Starting in ruby 3.3.0-preview2, attempting to require bigdecimal, mutex_m, base64, or other libraries that will move to bundled gems in Ruby 3.4.0 results in a warning, even when bundler is not in use:
```
$ ruby33 -v -r bigdecimal ...
jeremyevans0 (Jeremy Evans)
10:25 PM Revision 89bd1ebc (git): [ruby/yarp] Fix unexpected { after method call with args
https://github.com/ruby/yarp/commit/fe279d2d16 jemmai (Jemma Issroff)
10:24 PM Revision c2f7dae3 (git): [ruby/yarp] Handle unterminated interpolated symbol
https://github.com/ruby/yarp/commit/9222faa1c6 kddnewton (Kevin Newton)
10:24 PM Revision d2c75bb9 (git): [ruby/yarp] Handle missing terminators in parenthesized expression
https://github.com/ruby/yarp/commit/a8b54e8ed0 kddnewton (Kevin Newton)
10:24 PM Revision ffe77c02 (git): [ruby/yarp] Handle infinite opt terms after missing case predicate
https://github.com/ruby/yarp/commit/d931e258d1 kddnewton (Kevin Newton)
10:22 PM Revision bbf9f11c (git): [ruby/yarp] Fix behaviour of locations for comments
https://github.com/ruby/yarp/commit/b1ced67fba Andy Waite
10:01 PM Revision 010017d8 (git): [rubygems/rubygems] Reduce array allocations and concatenations in Index
Remove the default nested hash in Index entirely
Index#search_all now yields or returns enum since that's what caller
needs.
https://github.com/rubygems/rubygems/commit/c45ea3bbe2
martinemde (Martin Emde)
10:01 PM Revision 2cf5fe58 (git): [rubygems/rubygems] Avoid allocating empty hashes in Index
Since the hashes have a default proc that returns a (new) empty hash, we
can avoid allocating those empty hashes when we are only doing lookups.
Test from running `bundle update --bundler` against a rails app I have
lying around:
```
=...
segiddins (Samuel Giddins)
09:47 PM Revision 4e8869c6 (git): [ruby/yarp] Use templated constants for Regexp options
https://github.com/ruby/yarp/commit/38e1769c2e Tim Morgan
09:47 PM Revision 101ac364 (git): [ruby/yarp] Return Regexp options that match MRI for e, u, s, and n
https://github.com/ruby/yarp/commit/17dbf4ec46 Tim Morgan
08:15 PM Revision 0996cf55 (git): YJIT: Fix and enable the unused_imports warning
alanwu (Alan Wu)
06:38 PM Feature #19842: Introduce M:N threads
> this branch is bit of unstable.
If so, the sooner it's merge the sooner we can help stabilize it, and the more time we have to do so before release.
byroot (Jean Boussier)
06:02 PM Revision 4012ba4e (git): [ruby/yarp] Fix string delimiter with "@" confused for embedded
variable
(https://github.com/ruby/yarp/pull/1521)
https://github.com/ruby/yarp/commit/3ec0699622
jemmai (Jemma Issroff)
05:59 PM Revision e50b7bf7 (git): [DOC] Globals doc (#8445)
burdettelamar (Burdette Lamar)
05:54 PM Revision c423d6e0 (git): [rubygems/rubygems] Stop allocating the same settings keys repeatedly
Running `bundle update --bundler` on a rails app locally:
```
==> memprof.after.txt <==
Total allocated: 301.90 kB (3794 objects)
Total retained: 73.24 kB (698 objects)
==> memprof.before.txt <==
Total allocated: 14.47 MB (196378 obje...
segiddins (Samuel Giddins)
05:24 PM Revision 4d86d932 (git): Free all heap pages at shutdown
previously heap_allocated_pages was decremented from heap_page_free causing only half the heap pages to be freed at shutdown HParker (Adam Hess)
04:01 PM Revision a1dc1a3d (git): Return line 0 for JIT frames
Frames pushed by YJIT have an unreliable PC. The PC could be garbage,
and if we try to read the line number with a garbage PC, then the
program can crash.
This commit returns line 0 for programs where there is a `jit_return`
function. ...
tenderlovemaking (Aaron Patterson)
03:45 PM Revision efe28227 (git): Process.warmup: invoke `malloc_trim` if available
Similar to releasing free GC pages, releasing free malloc pages
reduce the amount of page faults post fork.
byroot (Jean Boussier)
03:41 PM Revision 28fe8846 (git): [ruby/yarp] Add more tests for implicit hash values
https://github.com/ruby/yarp/commit/1ddd74dc11 kddnewton (Kevin Newton)
03:41 PM Revision 5f9f2fd7 (git): [ruby/yarp] Add implicit nodes for ommitted hash values
https://github.com/ruby/yarp/commit/22130b3491 kddnewton (Kevin Newton)
03:14 PM Revision 5a6eae0b (git): [ruby/yarp] Keep value for invalid local variable write in tree
https://github.com/ruby/yarp/commit/eaafc829db kddnewton (Kevin Newton)
03:14 PM Revision fab25082 (git): [ruby/yarp] Ensure owned constants are marked as shared when overtaken
https://github.com/ruby/yarp/commit/d73f7c9cfa kddnewton (Kevin Newton)
03:14 PM Revision b5084877 (git): [ruby/yarp] Disallow numbered parameters in multiple scopes
https://github.com/ruby/yarp/commit/5fd4d3b89a kddnewton (Kevin Newton)
03:14 PM Revision a4b4ebc7 (git): [ruby/yarp] Error when numbered parameters are written
https://github.com/ruby/yarp/commit/65b536ba12 kddnewton (Kevin Newton)
03:14 PM Revision 6031ab18 (git): [ruby/yarp] Support parsing numbered parameters
https://github.com/ruby/yarp/commit/ffc8f35e56 kddnewton (Kevin Newton)
03:14 PM Revision 236fe914 (git): [ruby/yarp] Track explicit parameters on blocks
https://github.com/ruby/yarp/commit/99c91931e0 kddnewton (Kevin Newton)
03:14 PM Revision 1badb09f (git): [ruby/yarp] Properly handle missing method names
https://github.com/ruby/yarp/commit/4a30c69051 kddnewton (Kevin Newton)
01:13 PM Bug #18257: rb_mRubyVMFrozenCore is broken by GC run
Trying to reproduce all the steps, I still observe the behavior as described in comment #18257-12. I'll keep around the patch as described in #18257-14 until this is fixed properly. vo.x (Vit Ondruch)
12:32 PM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
nobu (Nobuyoshi Nakada) wrote in #note-7:
> These are all generated by the same compiler?
Yes - FreeBSD clang version 14.0.5. I also try 15.0.7 to no effect.
gcc 12.2.0 performs much better, though it too has a slightly more mo...
Freaky (Thomas Hurst)
06:13 AM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
Attaching the generated code by gcc version 11.4.0 (Ubuntu 11.4.0-1ubuntu1~22.04).
This seems vectorizing per 16 bytes.
```S
movdqu (%rdi), %xmm2 # MEM <vector(16) unsigned char> [(unsigned char *)_95], tmp383
addq $16, %rdi #, i...
nobu (Nobuyoshi Nakada)
05:43 AM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
Freaky (Thomas Hurst) wrote in #note-6:
> Annotated disassemblies attached.
Thank you.
These are all generated by the same compiler?
The "slow" version scans per WORD (= 2bytes), while the "fast" version uses DWORD (= 4bytes).
nobu (Nobuyoshi Nakada)
04:31 AM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
Annotated disassemblies attached. Freaky (Thomas Hurst)
03:40 AM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
byroot (Jean Boussier) wrote in #note-4:
> > May you please help me to find the root cause?
> ...
Tried `objdump --disassemble=rb_str_count` on Ubuntu 22.04, but the shared library is stripped and has no symbols.
> @alanwu guessed t...
nobu (Nobuyoshi Nakada)
10:55 AM Bug #19882 (Closed): :$0x should be rejected
Applied in changeset commit:git|89802078f9f406be411032814e1960e62dbc7ce2.
----------
[Bug #19882] Reject tokens invalid as symbols
nobu (Nobuyoshi Nakada)
09:04 AM Bug #19882: :$0x should be rejected
https://github.com/ruby/ruby/pull/8450 nobu (Nobuyoshi Nakada)
05:03 AM Bug #19882: :$0x should be rejected
It's subtly intentional.
The former seemed better to me.
```
$ ruby -e '$01234'
-e:1: identifier $01234 is not valid to get
-e: compile error (SyntaxError)
```
```
$ ./ruby -e 'p :$01234'
-e:1: syntax error, unexpected integ...
nobu (Nobuyoshi Nakada)
09:57 AM Feature #19884: Make Safe Navigation Operator work on classes
I am not sure that pattern is that common to warrant using &., aside from the syntax not being very elegant, but that may be my own bias against it (syntax-wise that is). I don't seem to need to do "defined?(Foo::Bar) && Foo::Bar.some_me... rubyFeedback (robert heiler)
08:11 AM Feature #19884: Make Safe Navigation Operator work on classes
Currently, you can do `ActiveRecord::Base.some_method rescue nil`
Using `&.` for rescuing an error in addition to the current behavior would make it confusing.
Furthermore, the specification you are asking for is not clear. What Except...
sawa (Tsuyoshi Sawada)
08:06 AM Feature #19884 (Open): Make Safe Navigation Operator work on classes
If a constant isn't defined it will raise a NameError:
```ruby
DoesNotExist.some_method # raises: uninitialized constant DoesNotExist (NameError)
```
In libraries that have optional dependencies, we can check if the constant is d...
p8 (Petrik de Heus)
08:46 AM Feature #19839: Need a method to check if two ranges overlap
I opened a PR about a month ago but should I close it...? https://github.com/ruby/ruby/pull/8242 shouichi (Shouichi Kamiya)
08:27 AM Revision 89802078 (git): [Bug #19882] Reject tokens invalid as symbols
nobu (Nobuyoshi Nakada)
08:05 AM Revision 5a7f5bb0 (git): Bump actions/checkout from 3.6.0 to 4.0.0
Bumps [actions/checkout](https://github.com/actions/checkout) from 3.6.0 to 4.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](http...
dependabot[bot]
08:01 AM Misc #19883 (Closed): DevMeeting-2023-10-12
# The next dev meeting
**Date: 2023/10/12 13:00-17:00** (JST)
Log: *TBD*
- Dev meeting *IS NOT* a decision-making place. All decisions should be done at the bug tracker.
- Dev meeting is a place we can ask Matz, nobu, nurse and o...
mame (Yusuke Endoh)
08:01 AM Misc #19858 (Closed): DevMeeting-2023-09-14
mame (Yusuke Endoh)
04:27 AM Bug #19778 (Closed): mkmf.rb pkg_config() interaction with RbConfig::CONFIG["cflags"]
Applied in changeset commit:git|fe0225ff4d5af8b1f54009727b39d0d9b821eea3.
----------
[Bug #19778] Add `-I` options for opt-dir to `$INCFLAGS`
These options have been separated from `$CFLAGS` already in the
other places.
nobu (Nobuyoshi Nakada)
03:52 AM Bug #19778: mkmf.rb pkg_config() interaction with RbConfig::CONFIG["cflags"]
https://github.com/ruby/ruby/pull/8449 nobu (Nobuyoshi Nakada)
04:27 AM Revision fe0225ff (git): [Bug #19778] Add `-I` options for opt-dir to `$INCFLAGS`
These options have been separated from `$CFLAGS` already in the
other places.
nobu (Nobuyoshi Nakada)
03:20 AM Revision 74277f99 (git): Bump ruby/setup-ruby from 1.152.0 to 1.153.0
Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.152.0 to 1.153.0.
- [Release notes](https://github.com/ruby/setup-ruby/releases)
- [Commits](https://github.com/ruby/setup-ruby/compare/250fcd6a742febb1123a77a841497ccaa8...
dependabot[bot]
02:08 AM Bug #9115: Logger traps all exceptions; breaks Timeout
Eregon (Benoit Daloze) wrote in #note-12:
> mame (Yusuke Endoh) wrote in #note-11:
> ...
Right. It's never an ultimate fix. However considering the way a log destination is designed generally, I think it's rare for that blocking IO t...
shyouhei (Shyouhei Urabe)
01:33 AM Bug #19873 (Closed): Thread#native_thread_id is incorrectly cached across fork on Linux
Applied in changeset commit:git|0117a6d389c5b607eaec1b7f917132efa356f665.
----------
Fix Thread#native_thread_id being cached across fork (#8418)
The native thread ID can and does change on some operating systems (e.g.
Linux) after for...
Anonymous
01:33 AM Revision 0117a6d3 (git): Fix Thread#native_thread_id being cached across fork (#8418)
The native thread ID can and does change on some operating systems (e.g.
Linux) after forking, so it needs to be re-queried.
[Bug #19873]
KJ Tsanaktsidis

09/14/2023

11:31 PM Feature #19842: Introduce M:N threads
@tenderlovemaking We can merge this with ko1's convenience. We needed to skip this for preview2 because ko1 said this branch is bit of unstable. hsbt (Hiroshi SHIBATA)
11:17 PM Feature #19842: Introduce M:N threads
Any idea when / if we will merge this? Or, is there anything preventing us to merge? tenderlovemaking (Aaron Patterson)
11:15 PM Revision f08cac06 (git): Don't call malloc with 0
It seems not-uncommon for methods to have no IV, ISE, or ICVARC caches.
Calling malloc with 0 will actually allocate something, so if there
aren't any caches (`ISEQ_IS_SIZE(body) == 0`), then we can avoid
allocating memory by not calling...
tenderlovemaking (Aaron Patterson)
10:49 PM Revision 982d6503 (git): YJIT: Skip Insn::Comment and format! if disasm is disabled (#8441)
* YJIT: Skip Insn::Comment and format!
if disasm is disabled
Co-authored-by: Alan Wu <alansi.xingwu@shopify.com>
* YJIT: Get rid of asm.comment
---------
Co-authored-by: Alan Wu <alansi.xingwu@shopify.com>
k0kubun (Takashi Kokubun)
10:40 PM Revision 0ba6c603 (git): YJIT: Remove UTF-8 BOM [ci skip]
/yjit/src/backend/x86_64/mod.rs Is also UTF-8 and it doesn't have the
marker. The standard recommends against it, so remove it.
alanwu (Alan Wu)
10:02 PM Revision 07b615bb (git): Skip renaming OpenSSL DLLs
to fix CI failures like:
https://github.com/ruby/ruby/actions/runs/6190995187/job/16808382442
k0kubun (Takashi Kokubun)
09:18 PM Revision 1961c5bb (git): YJIT: Plug native stack overflow
Previously, TestStack#test_machine_stack_size failed pretty consistently
on ARM64 macOS, with Rust code and part of the interpreter used for
per-instruction fallback (rb_vm_invokeblock() and friends) touching the
stack guard page and cra...
alanwu (Alan Wu)
07:43 PM Revision 66ffa15c (git): [rubygems/rubygems] Gemfile ruby file: covers more version formats
Increase test coverage and be explicit about what is and is not supported.
https://github.com/rubygems/rubygems/commit/a096397a00
martinemde (Martin Emde)
07:16 PM Revision 0d33bc0c (git): [ruby/yarp] Simplify multi-target parsing
This simplifies how we handle multi-targets, and also fixes a bug we
had where for loops were always getting multi-targets, even when there
was only a single target.
https://github.com/ruby/yarp/commit/31eb8b7ad5
kddnewton (Kevin Newton)
07:10 PM Revision 0a8f3670 (git): [ruby/yarp] Introduce MatchWriteNode
This rarely used node holds information about the local variables
that need to get written in the case a regular expression is used on
the left-hand side of a =~ operator and it has named capture groups.
Note that we already "handled" t...
kddnewton (Kevin Newton)
07:10 PM Revision 9d2549ac (git): [ruby/yarp] Write names should not underflow size_t
If the read_name is invalid, we shouldn't try to set a write name.
https://github.com/ruby/yarp/commit/06881c8ca7
kddnewton (Kevin Newton)
06:38 PM Bug #19882: :$0x should be rejected
Don't overlook the colon! mame (Yusuke Endoh)
06:23 PM Bug #19882: :$0x should be rejected
I think it is rejected at the moment:
```
-e:1: identifier $0x is not valid to get
-e: compile error (SyntaxError)
```
kddnewton (Kevin Newton)
06:13 PM Bug #19882 (Closed): :$0x should be rejected
```
irb(main):001> :$0x
=> :"$0x"
```
Since `$0x` is not a valid global variable name, I think it should be rejected unless quotation marks are used.
mame (Yusuke Endoh)
06:32 PM Revision 63d1e056 (git): [ruby/yarp] Handle errors when operator writes on a call with a block
https://github.com/ruby/yarp/commit/93bec2c173 kddnewton (Kevin Newton)
06:31 PM Revision fb1328e4 (git): [ruby/yarp] Fix multi target parentheses locations
https://github.com/ruby/yarp/commit/7f71527522 kddnewton (Kevin Newton)
06:31 PM Revision b098c424 (git): [ruby/yarp] Remove deprecated aliases
https://github.com/ruby/yarp/commit/db28e22363 kddnewton (Kevin Newton)
06:30 PM Revision de2fe863 (git): [ruby/yarp] Extract out parse_write_name
https://github.com/ruby/yarp/commit/0d3e8cdcd7 kddnewton (Kevin Newton)
06:30 PM Revision 826bebb7 (git): [ruby/yarp] Reject invalid call-operator-write
https://github.com/ruby/yarp/commit/d3a852dac2 kddnewton (Kevin Newton)
06:28 PM Revision 7f6cf2d2 (git): [ruby/yarp] Use bytes instead of bit fields
https://github.com/ruby/yarp/commit/890fa72fdd kddnewton (Kevin Newton)
06:28 PM Revision 581bda0c (git): [ruby/yarp] Add a frozen string flag
https://github.com/ruby/yarp/commit/09248a1f9e kddnewton (Kevin Newton)
06:28 PM Revision 282e4388 (git): [ruby/yarp] Introduce a flag for a static literal check
https://github.com/ruby/yarp/commit/c61658c0fd kddnewton (Kevin Newton)
06:28 PM Revision 500f38e0 (git): [ruby/yarp] Parse frozen string literal comment
https://github.com/ruby/yarp/commit/373898e7cb kddnewton (Kevin Newton)
06:28 PM Revision 122f3d64 (git): [ruby/yarp] Move booleans on the parser to the end so they are more compact
https://github.com/ruby/yarp/commit/21a43034d0 kddnewton (Kevin Newton)
06:16 PM Revision 533c4072 (git): [YARP] Fix up alias and true node (#8423)
* [YARP] Use ALIAS_METHOD as opposed to ALIAS
* [YARP] Use YP_TRUE_NODE instead of YP_NODE_TRUE_NODE
kddnewton (Kevin Newton)
06:11 PM Bug #19881: Unary operators on calls without parentheses
My uncertain understanding is that an expression (called "arg" in parse.y) must come after the unary minus. Since `foo 1, 2, 3` is not an expression but a statement (called "command" in parse.y), `- foo 1, 2, 3` is not acceptable. mame (Yusuke Endoh)
04:46 PM Bug #19881 (Rejected): Unary operators on calls without parentheses
At the moment it appears that you can't use unary operators when you have a call without parentheses. For example:
``` ruby
- foo 1, 2, 3
```
This seems useful, particularly for methods that perform calculations.
I'm also aski...
kddnewton (Kevin Newton)
05:55 PM Revision fcc16991 (git): YJIT: Initialize Vec with capacity for iterators (#8439)
k0kubun (Takashi Kokubun)
05:29 PM Bug #19877 (Closed): Non intuitive behavior of syntax only applied to literal value
Applied in changeset commit:git|e8896a31d48e5797df3878696dcb50aed85b87c2.
----------
[Bug #19877] Literals cannot have singleton methods even in blocks
nobu (Nobuyoshi Nakada)
04:23 PM Feature #19720: Warning for non-linear Regexps
I agree with Matz, false positives are worse than no warnings at all. I use atomic groups and positive/negative lookahead/lookbehind all the time. In particular, atomic groups are a great tool to *prevent* ReDoS-susceptible regexps, so t... Dan0042 (Daniel DeLorme)
10:22 AM Feature #19720: Warning for non-linear Regexps
If "non-linear" means real non-linear, I would not object. But in this case, “non-linear” means the recent memoize optimization cannot be applied. So if we add this warning, we will get a lot of false positives from safe regular expressi... matz (Yukihiro Matsumoto)
04:09 PM Revision 9cb33aad (git): [Bug #19877] Fix flip-flop in block
nobu (Nobuyoshi Nakada)
04:09 PM Revision 864bb868 (git): [Bug #19877] Named captures should take place from regexps in block
nobu (Nobuyoshi Nakada)
04:09 PM Revision e8896a31 (git): [Bug #19877] Literals cannot have singleton methods even in blocks
nobu (Nobuyoshi Nakada)
04:09 PM Revision 3f492921 (git): Reuse `rb_reg_named_capture_assign_iter_impl`
nobu (Nobuyoshi Nakada)
03:11 PM Revision 6df0927b (git): [ruby/yarp] Remove varargs entirely
Following up on #1483, this removes our usage of varargs entirely.
Under the new approach we make explicit methods for the various
signatures. Because we know the type of everything any it's very
consistent, this makes it easier for comp...
kddnewton (Kevin Newton)
02:44 PM Bug #9115: Logger traps all exceptions; breaks Timeout
mame (Yusuke Endoh) wrote in #note-11:
> As a better-than-nothing mitigation, it is proposed to enclose the entire `Logger::LogDevice#write` in `Thread.handle_interrupt(:never) { ... }`.
> ...
This sounds problematic, especially since ...
Eregon (Benoit Daloze)
01:52 PM Bug #9115: Logger traps all exceptions; breaks Timeout
Discussed at the dev meeting.
* It is clear that Logger has the intention not to interfere with the execution of the application on a log write failure.
* On the other hand, it is also clear that Logger is not considering about async...
mame (Yusuke Endoh)
02:17 PM Feature #19849: Requiring file with autoload results in confusing error if file doesn't exist
Briefly discussed at the dev meeting.
We understand the problem, but doesn't find a good solution. Since the call line of autoload does not exist in the call stack when the exception occurs, it cannot be displayed as a backtrace.
It ...
mame (Yusuke Endoh)
02:10 PM Feature #19850 (Rejected): Get thread creation time
We discussed this at the dev meeting, and decided not to implement it.
Considering frameworks that implement a thread pool, the time when a Thread object is created is not necessarily useful, but could be rather confusing. It would be...
mame (Yusuke Endoh)
08:22 AM Feature #19850: Get thread creation time
To investigate when you want to investigate what causes a program hang...
## pid2line
https://gist.github.com/nurse/0619b6af90df140508c2
It shows what threads are running or sleeping and where it is as C function name.
In your ca...
naruse (Yui NARUSE)
02:10 PM Revision cdc69da9 (git): YJIT: Initialize Assembler vectors with capacity (#8437)
k0kubun (Takashi Kokubun)
02:04 PM Feature #19859: Start & Finish, Begin & End
I confirmed that, at least, Java, Python, JavaScript, Rust, .NET, PHP, and OCaml are using starts_with/ends_with or similar.
https://docs.oracle.com/en/java/javase/20/docs/api/java.base/java/lang/String.html#startsWith(java.lang.String)...
mame (Yusuke Endoh)
07:46 AM Feature #19859 (Closed): Start & Finish, Begin & End
We have picked that pair (inspired by Java). Adding infinite number of variation seems not to be a good idea.
Matz.
matz (Yukihiro Matsumoto)
01:58 PM Revision 1b6d2b91 (git): [ruby/yarp] Fix up unary minus precedence
https://github.com/ruby/yarp/commit/6be28eeed0 kddnewton (Kevin Newton)
01:58 PM Revision 174aa536 (git): [ruby/yarp] Handle concat character literal and string
https://github.com/ruby/yarp/commit/fb141b8d07 kddnewton (Kevin Newton)
01:58 PM Revision 57745450 (git): [ruby/yarp] Extract out heredoc parsing into parse_strings
https://github.com/ruby/yarp/commit/c5a1094988 kddnewton (Kevin Newton)
01:58 PM Revision 72d008d8 (git): [ruby/yarp] Extract out parse_strings
https://github.com/ruby/yarp/commit/55446f7a43 kddnewton (Kevin Newton)
01:52 PM Bug #19867 (Rejected): Unicode line and paragraph separator are not stripped
nobu (Nobuyoshi Nakada)
01:48 PM Feature #19839: Need a method to check if two ranges overlap
https://github.com/nobu/ruby/tree/Range%23overlap_p nobu (Nobuyoshi Nakada)
09:49 AM Feature #19839: Need a method to check if two ranges overlap
I think the analogue for `range1.overlap?(range2)` in mathematics is `interval1 ∩ interval2 ≠ ∅`, which does not hold when either `interval1` or `interval2` is an empty interval.
Hence, I think that, when either `range1` or `range2` is ...
sawa (Tsuyoshi Sawada)
08:53 AM Feature #19839: Need a method to check if two ranges overlap
Although I said “accepted”, we found some corner cases which are not clear (e.g. #note-11). We have to make these cases clear before merging it to the core.
Matz.
matz (Yukihiro Matsumoto)
08:36 AM Feature #19839: Need a method to check if two ranges overlap
I'm not sure what `(n...n)` means but on AS definition, the following code return true.
```ruby
p (1..2).overlap?(2...2) #=> true
p (2..2).overlap?(2...2) #=> true
p (2...2).overlap?(2...2) #=> true
```
is it intentional?
ko1 (Koichi Sasada)
08:17 AM Feature #19839: Need a method to check if two ranges overlap
Accepted. It must be useful without ActiveSupport.
Matz.
matz (Yukihiro Matsumoto)
01:43 PM Revision b85bb90c (git): [DOC] Sort "Core classes updates" section
Alphabetically by class or module names. nobu (Nobuyoshi Nakada)
01:39 PM Revision 9a1c5a12 (git): [ruby/yarp] Handle invalid operator write on fcall
https://github.com/ruby/yarp/commit/22c800eab1 kddnewton (Kevin Newton)
01:36 PM Bug #17146: Queue operations are allowed after it is frozen
I would like to add a point that came up during the dev meeting: if a thread is waiting for `Queue#pop`, and another thread freezes the Queue, what should the first thread do? Wait forever? Raise a FrozenError?
To raise a FrozenError,...
mame (Yusuke Endoh)
05:37 AM Bug #17146: Queue operations are allowed after it is frozen
Since frozen `queue` is meaningless, if you care about consistency, we should prohibit `freeze` queues, like `ENV`.
Matz.
matz (Yukihiro Matsumoto)
12:17 PM Revision c95f3447 (git): [ruby/yarp] get rid of `accept_any_p` and just use regular functions
https://github.com/ruby/yarp/commit/4512daf769 froydnj (Nathan Froyd)
12:17 PM Revision a921d4be (git): [ruby/yarp] don't use varargs for common cases of `match_any_type_p`
https://github.com/ruby/yarp/commit/79794b4833 froydnj (Nathan Froyd)
12:17 PM Revision 99023401 (git): [ruby/yarp] add some `const` qualifiers
https://github.com/ruby/yarp/commit/e807462c6d froydnj (Nathan Froyd)
09:47 AM Feature #19735: Add support for UUID version 7
We core committers discussed this issue on DevMeeting, and we accepted it.
Go ahead
usa (Usaku NAKAMURA)
08:37 AM Revision a095740f (git): Fix `io_buffer_get_string` default length computation. (#8427)
* Fix `io_buffer_get_string` default length computation.
When an offset bigger than the size is given, the resulting length will be
computed incorrectly. Raise an argument error in this case.
* Validate all arguments.
Samuel Williams
08:25 AM Feature #19832 (Rejected): Method#destructive?, UnboundMethod#destructive?
It should be fundamentally covered by the reference document.
Matz.
matz (Yukihiro Matsumoto)
08:02 AM Misc #19860 (Rejected): Update license phrases to SPDX BSD-2-Clause
A license term is not easy to change.
Also note that Ruby consists from many code which use difference license.
Therefore I think changing license text to match with SPDX is not a good proposal.
naruse (Yui NARUSE)
07:41 AM Bug #19868 (Closed): `Process::Status` methods for compatibility with `Fixnum`
Applied in changeset commit:git|b6de0a6c69a4857ca4347f65d7c9a5cb6e52c5bd.
----------
[Bug #19868] Suggest other Process::Status method for `&` and `>>`
`Process::Status#&` and `Process::Status#>>` are provided only for
the backward com...
nobu (Nobuyoshi Nakada)
06:26 AM Revision 998ae7c3 (git): [Bug #19868] Deprecate `Process::Status#&` and `Process::Status#>>`
nobu (Nobuyoshi Nakada)
05:57 AM Revision b6de0a6c (git): [Bug #19868] Suggest other Process::Status method for `&` and `>>`
`Process::Status#&` and `Process::Status#>>` are provided only for
the backward compatibility with older Ruby than 1.8 where `$?` was
a `Fixnum`, and the knowledge about internals of system dependent
macros is necessary to use them. Mod...
nobu (Nobuyoshi Nakada)
05:47 AM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
Currently, it gives the place we called `autoload`. If you want the place where the loaded module defined (after autoload), you can explicitly reference the module before calling `const_source_location`. So I vote for keeping it as it is... matz (Yukihiro Matsumoto)
05:38 AM Revision efe5e6e8 (git): Negative value to Process::Status method for compatibility
nobu (Nobuyoshi Nakada)
05:07 AM Feature #19075 (Closed): Binary searching for the last element
We reject `bsearch_last`, it's not intuitive (from my POV). If we come up with good name candidates, resubmit the proposal.
Matz.
matz (Yukihiro Matsumoto)
01:09 AM Revision e50fcca9 (git): [ruby/yarp] make some encoding tables `const`
https://github.com/ruby/yarp/commit/777c376deb froydnj (Nathan Froyd)

09/13/2023

11:42 PM Revision f644996f (git): For YJIT Actions, don't filter test-spec backtraces
I'm trying to debug a flaky `RuntimeError: nested #it` failure in
ruby/spec. Hopefully the full backtrace will give some clues.
Last occurence:
https://github.com/ruby/ruby/actions/runs/6172578817/job/16753137038
alanwu (Alan Wu)
09:26 PM Revision 3d453bc6 (git): [ruby/yarp] free strings in the ruby extension
https://github.com/ruby/yarp/commit/87dbb6cf1f froydnj (Nathan Froyd)
08:44 PM Revision b49be2a7 (git): YJIT: Skip adding past_page_bytes for past pages (#8433)
YJIT: Skip adding past_pages_bytes for past pages k0kubun (Takashi Kokubun)
07:16 PM Feature #19832: Method#destructive?, UnboundMethod#destructive?
IMO this feature wouldn't really add anything new to ractors that I can think of, because ractors already work with either new "moved" objects or deeply frozen objects, which can still have methods called on them inside the ractors. For ... luke-gru (Luke Gruber)
05:37 PM Revision 7f6c0efa (git): Fix hyperlink for Script Encoding
herwin (Herwin W)
05:31 PM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
> May you please help me to find the root cause?
A start would be to decompile `rb_str_count` on two versions.
@alanwu guessed that it might be the change from signed to unsigned that is preventing some compilers from auto-vectoriz...
byroot (Jean Boussier)
04:22 PM Bug #19875: Ruby 3.0 -> 3.1 Performance regression in String#count
Thanks for your feedback, @nobu! It looks like compiler dependent. I used `x86_64-linux`.
May you please help me to find the root cause? (*I'll do my own research, just asking for starting points.* )
iz (Illia Zub)
01:36 AM Bug #19875 (Feedback): Ruby 3.0 -> 3.1 Performance regression in String#count
It seems compiler dependent.
My results on x86_64-darwin are:
```
$ ruby -I ./benchmark/benchmark-driver/lib/ benchmark/benchmark-driver/exe/benchmark-driver ~/tmp/string_count_benchmark_driver.yml --executables=/opt/local/bin/ruby{...
nobu (Nobuyoshi Nakada)
03:08 PM Bug #19880 (Closed): Missing write barrier in iseq instruction list
peterzhu2118 (Peter Zhu)
03:08 PM Bug #19880 (Closed): Missing write barrier in iseq instruction list
There's a missing write barrier for operands in the iseq instruction list, which can cause crashes. This bug has been fixed in commit [b3b57f7](https://github.com/ruby/ruby/commit/b3b57f70cc1ee6f40ff10b2abaa51889abce2331).
It can be r...
peterzhu2118 (Peter Zhu)
02:48 PM Revision ff329ce4 (git): YJIT: Make yjit_alloc_size available by default (#8426)
k0kubun (Takashi Kokubun)
02:45 PM Revision 721d21d3 (git): YJIT: Make compile_time_ns a default counter (#8425)
k0kubun (Takashi Kokubun)
02:37 PM Bug #18257: rb_mRubyVMFrozenCore is broken by GC run
I don't think this is resolved, at least to the full extent. Trying again with the patch from comment #18257-13 and this is the results:
~~~
$ ./miniruby -v
ruby 3.3.0dev (2023-09-05 master 7c8932365f) [x86_64-linux]
$ ./miniruby -e "1...
vo.x (Vit Ondruch)
02:30 PM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
I said this could be useful for debugging. If a user finds a call to `autoload` on the line pointed to by `const_source_location`, they can guess that autoload is set. If they want to know the actual definition location, they can actuall... mame (Yusuke Endoh)
12:38 PM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
mame (Yusuke Endoh) wrote in #note-16:
> Why do you want to know the location of the autoload call after it is actually loaded?
I do not know. I do not understand in the first place your use case where you want to identify where a co...
sawa (Tsuyoshi Sawada)
10:44 AM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
Why do you want to know the location of the autoload call after it is actually loaded? I guess that information is already gone from the runtime as well. mame (Yusuke Endoh)
05:55 AM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
mame (Yusuke Endoh) wrote in #note-14:
> As I said, you can use it safely in conjunction with `Module.autoload?`.
> ...
What I meant is that, once you are in a location beyond where `A` was called, you cannot reference the call site an...
sawa (Tsuyoshi Sawada)
05:11 AM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
sawa (Tsuyoshi Sawada) wrote in #note-13:
> You cannot safely use `const_source_location` to extract the autoload call site since the return value depends on whether the constant is called or not:
As I said, you can use it safely in ...
mame (Yusuke Endoh)
04:07 AM Bug #17354: Module#const_source_location is misleading for constants awaiting autoload
mame (Yusuke Endoh) wrote in #note-11:
> 2. If we want to identify where a constant is set as autoload, we can use the current `Module#const_source_location`.
> ...
You cannot safely use `const_source_location` to extract the autoload ca...
sawa (Tsuyoshi Sawada)
01:50 PM Revision 90838a94 (git): [ruby/yarp] Fix associativity for a couple of operators
https://github.com/ruby/yarp/commit/820774976d kddnewton (Kevin Newton)
01:40 PM Revision f9898b9e (git): [ruby/yarp] Better handle invalid gvar writes
https://github.com/ruby/yarp/commit/eaaebc17c8 kddnewton (Kevin Newton)
12:48 PM Revision ea75a682 (git): [ruby/yarp] Mark empty flags as well as locations and blocks
https://github.com/ruby/yarp/commit/b74ce35379 nobu (Nobuyoshi Nakada)
12:40 PM Bug #19878 (Closed): Math.log is broken for bignum
Applied in changeset commit:git|411572661a3995a0daacb6c866ea3ac6b52ad25b.
----------
math.c: Fix Math.log against huge bignum [Bug #19878]
mame (Yusuke Endoh)
09:59 AM Bug #19878: Math.log is broken for bignum
Fortunately, this bug was introduced this year on commit:da39936ce165ea9462b9e192eb6b608485c94842 so no need to backport. mame (Yusuke Endoh)
09:58 AM Bug #19878: Math.log is broken for bignum
https://github.com/ruby/ruby/pull/8429 mame (Yusuke Endoh)
09:54 AM Bug #19878 (Closed): Math.log is broken for bignum
```ruby
p Math.log(2 ** 1020, 10) #=> 307.0505955772608
p Math.log(2 ** 1021, 10) #=> 307.35162557292483
p Math.log(2 ** 1022, 10) #=> 307.6526555685888
p Math.log(2 ** 1023, 10) #=> 688.6994720982339 <- WHAT!?
p Math.log(2 ** 1024,...
mame (Yusuke Endoh)
12:40 PM Revision a0e66873 (git): Use log2(b) instead of (log(b) / M_LN2)
Co-Authored-By: Nobuyoshi Nakada <nobu@ruby-lang.org> mame (Yusuke Endoh)
12:40 PM Revision 41157266 (git): math.c: Fix Math.log against huge bignum [Bug #19878]
mame (Yusuke Endoh)
12:31 PM Bug #19879 (Third Party's Issue): GC crash during Rails app testing
```
/opt/hostedtoolcache/Ruby/3.1.3/x64/lib/libruby.so.3.1(objspace_xmalloc0.cold+0x0) [0x7f07a3fbfa2f]
[0x7f079983999e]
/opt/hostedtoolcache/Ruby/3.1.3/x64/lib/libruby.so.3.1(obj_free+0x632) [0x7f07a4080282]
/opt/hostedtoolcache/Rub...
byroot (Jean Boussier)
10:42 AM Bug #19879 (Third Party's Issue): GC crash during Rails app testing
In a Github action (using https://github.com/ruby/setup-ruby latest) for a rails app, I am seeing the following error when trying to run the test suite (RSpec). The tests have been running OK for a while, but recently this started happen... johansenjaa (Joseph Johansen)
09:44 AM Bug #19754: `IO::Buffer#get_string` raises unsuitable exception for too large offset
It also begs the question whether `NUM2SIZET` should allow negative values.. ioquatix (Samuel Williams)
09:44 AM Bug #19754: `IO::Buffer#get_string` raises unsuitable exception for too large offset
This change isn't sufficient, it just protects against the invalid value of offset. We can backport it, but I don't feel strongly about whether it's required or not. ioquatix (Samuel Williams)
09:22 AM Bug #19877 (Closed): Non intuitive behavior of syntax only applied to literal value
Non intuitive behavior of syntax only applied to literal value
Some ruby syntax is only applied to literal value.
~~~ruby
def 1.foo; end # receiver is a literal, it is Syntax Error
/(?<a>)/ =~ s # receiver is regexp literal, it wil...
tompng (tomoya ishida)
09:09 AM Bug #9115: Logger traps all exceptions; breaks Timeout
"defensive" code like that is just broken, no one should `rescue Exception`.
Let's remove that outer `rescue`?
If `synchronize` raises there is a serious bug worth fixing and not ignoring.
Similarly I think the inner `rescue`s shoul...
Eregon (Benoit Daloze)
09:03 AM Revision 4655d210 (git): Lrama v0.5.6
yui-knk (Kaneko Yuichiro)
09:00 AM Misc #19772: API naming for YARP compiler
@mame Thanks for the clarifications, notably about the name.
My impression is if YARP supports multiple Ruby grammar versions then basically everything discussed in this issue is solved (and no need to rename, and only C files of yarp a...
Eregon (Benoit Daloze)
07:23 AM Revision c75d54a3 (git): Fixup 1851824b1c7b816e41b567b5310bb18ab6f9ff7a
hsbt (Hiroshi SHIBATA)
07:07 AM Bug #19872: TestRequireLib#test_thread_size test case is unstable
Have not chance to test it yet, but the change LGTM. Thx! vo.x (Vit Ondruch)
01:43 AM Bug #19872 (Closed): TestRequireLib#test_thread_size test case is unstable
Applied in changeset commit:git|234722ed9fce33d7ec8152920636af663d527912.
----------
[Bug #19872] Refine TestRequireLib
Always test only the scripts just under “lib", and just under
child directories which has not the same name script ...
nobu (Nobuyoshi Nakada)
07:01 AM Revision 1851824b (git): [flori/json] alias_method is private on Ruby 2.3 and 2.4
https://github.com/flori/json/commit/573ef94bc5 hsbt (Hiroshi SHIBATA)
06:36 AM Feature #19075: Binary searching for the last element
FYI: Julia has `searchsortedfirst` and `searchsortedlast`
https://docs.julialang.org/en/v1/base/sort/#Base.Sort.searchsortedfirst
kyanagi (Kouhei Yanagita)
01:23 AM Feature #19075: Binary searching for the last element
(In the following, searching for the last element will be referred to as "LAST".)
There are often cases where searching for the last element would be useful.
A typical example that immediately comes to mind is as follows:
* When w...
kyanagi (Kouhei Yanagita)
05:58 AM Feature #19839: Need a method to check if two ranges overlap
I believe there are a few reasons for this addition. The core one I see often in justifications is precedence in existing Ruby, such as:
**Combinations**
These cases have clear precedent for iterable / enumerable types:
* `Array...
baweaver (Brandon Weaver)
05:19 AM Feature #19839: Need a method to check if two ranges overlap
Honestly, I can't give a formal reason. But I do believe it's a very basic operation. For example, postgres and boost provide such functionality.
- https://www.postgresql.org/docs/15/functions-range.html
- https://www.boost.org/doc/l...
shouichi (Shouichi Kamiya)
03:11 AM Revision e22086bb (git): Enable `.NOTPARALLEL` on `ripper_srcs`
And add special treats only for old GNU make. nobu (Nobuyoshi Nakada)
03:08 AM Misc #19858: DevMeeting-2023-09-14
* [Bug #17146] Queue operations are allowed after it is frozen (jeremyevans0)
* Last discussed at October 2020 developer meeting, no decision made.
* @headius and I discussed this at RubyKaigi and agreed it would be best to raise F...
jeremyevans0 (Jeremy Evans)
01:43 AM Revision 234722ed (git): [Bug #19872] Refine TestRequireLib
Always test only the scripts just under “lib", and just under
child directories which has not the same name script in the upper
level; instead of random sampling from whole libraries.
nobu (Nobuyoshi Nakada)
01:24 AM Revision 435b2439 (git): Suppress an unused variable warning
nobu (Nobuyoshi Nakada)
12:59 AM Bug #19876 (Closed): Equality chaining
Okay. I will make this behavior match. kddnewton (Kevin Newton)
12:55 AM Bug #19876: Equality chaining
I think it is by design. They are marked as `%nonassoc` in parse.y.
https://github.com/ruby/ruby/blob/6e64d4370456190541705ec4c6cf3af6bf4ac647/parse.y#L1698
```
%nonassoc tCMP tEQ tEQQ tNEQ tMATCH tNMATCH
```
mame (Yusuke Endoh)
12:46 AM Bug #19876 (Closed): Equality chaining
It appears that you cannot chain `==`, `!=`, `<=>`, `=~`, `!~`, `===`:
``` ruby
foo == bar == baz
```
but you can chain all of the other operators:
``` ruby
1 << 2 << 3
```
I'm not sure if I've missed some. I would just l...
kddnewton (Kevin Newton)
12:55 AM Revision c421f08f (git): [ruby/yarp] Handle parsing local variable singleton method definition
https://github.com/ruby/yarp/commit/943204d56f kddnewton (Kevin Newton)

09/12/2023

11:30 PM Bug #19862 (Closed): argument stack underflow compile error happens for the combination of and/or & one line pattern matching
Applied in changeset commit:git|6e64d4370456190541705ec4c6cf3af6bf4ac647.
----------
[Bug #19862] Skip compiled result of never reachable expression
nobu (Nobuyoshi Nakada)
11:30 PM Revision 6e64d437 (git): [Bug #19862] Skip compiled result of never reachable expression
nobu (Nobuyoshi Nakada)
11:28 PM Bug #19861 (Closed): Ripper does not fire any error event on unfinished heredoc
nobu (Nobuyoshi Nakada)
09:45 PM Bug #19754 (Closed): `IO::Buffer#get_string` raises unsuitable exception for too large offset
Applied in changeset commit:git|19346c2336053b351673da030b00c704138252d8.
----------
[Bug #19754] Make `IO::Buffer#get_string` check `offset` range (#8016)
nobu (Nobuyoshi Nakada)
05:27 AM Bug #19754 (Assigned): `IO::Buffer#get_string` raises unsuitable exception for too large offset
nobu (Nobuyoshi Nakada)
09:45 PM Revision 19346c23 (git): [Bug #19754] Make `IO::Buffer#get_string` check `offset` range (#8016)
nobu (Nobuyoshi Nakada)
09:32 PM Feature #19737 (Rejected): Add `IO::Buffer#cat` for concat `IO::Buffer` instances
It's probably not obvious given how existing Ruby code traditionally works, but in the above code, `a` and `b` are zero copy (which is ideal).
```
irb(main):001> data = "foo"
=> "foo"
irb(main):002> IO::Buffer.for(data)
=>
#<IO:...
ioquatix (Samuel Williams)
08:51 PM Misc #19772: API naming for YARP compiler
I would add that if the yarp gem had straight multi-version support like the parser gem, such a mechanism is not even needed. mame (Yusuke Endoh)
08:37 PM Misc #19772: API naming for YARP compiler
Hi @kddnewton
kddnewton (Kevin Newton) wrote in #note-22:
> From this thread and others, this is my understanding of the requirements:
> ...
There may be a communication error. More precisely,
* The `YARP` name is not good as a built-i...
mame (Yusuke Endoh)
08:33 PM Revision 11c32e33 (git): Adjust CGI spec to pass when ran in isolation
It failed with `NameError` because `Html3` is defined in the file that
`CGI::HtmlExtension` autoloads.
alanwu (Alan Wu)
08:31 PM Revision 5edabd1c (git): [DOC] RDoc for Process::Status (#8416)
burdettelamar (Burdette Lamar)
07:42 PM Revision d43765c3 (git): [rubygems/rubygems] Unify LockfileParser loading of SPECS section
Ensure unrecognized SPECS types are ignored
https://github.com/rubygems/rubygems/commit/5b33e91075
martinemde (Martin Emde)
05:52 PM Revision 0ae7f2d1 (git): YJIT: Add compilation time counter (#8417)
* YJIT: Add compilation time counter
* YJIT: Use Instant instead
k0kubun (Takashi Kokubun)
03:44 PM Revision a98209b8 (git): [ruby/yarp] Split AliasNode
Into AliasGlobalVariableNode and AliasMethodNode. These have different
enough semantics that we feel comfortable splitting them up.
https://github.com/ruby/yarp/commit/c1f3e6d344
kddnewton (Kevin Newton)
03:25 PM Feature #19777 (Closed): Make `Kernel#lambda` raise when called without a literal block
Applied in changeset commit:git|39ee3e22bd3d071c1c283b6b8dbd1af413342fb1.
----------
Make Kernel#lambda raise when given non-literal block
Previously, Kernel#lambda returned a non-lambda proc when given a
non-literal block and issued a...
alanwu (Alan Wu)
03:25 PM Revision 39ee3e22 (git): Make Kernel#lambda raise when given non-literal block
Previously, Kernel#lambda returned a non-lambda proc when given a
non-literal block and issued a warning under the `:deprecated` category.
With this change, Kernel#lambda will always return a lambda proc, if it
returns without raising.
...
alanwu (Alan Wu)
03:20 PM Revision b90272b3 (git): Fix typo in gc.c
peterzhu2118 (Peter Zhu)
02:28 PM Revision 385033ba (git): Ensure signaled processes at opening FIFO terminated
nobu (Nobuyoshi Nakada)
02:18 PM Bug #19875 (Open): Ruby 3.0 -> 3.1 Performance regression in String#count
`String#count` became slower since Ruby 3.1. Originally found by `@Freaky`: https://github.com/ruby/ruby/pull/4001#issuecomment-1714779781
Compared using the [`benchmark-driver` gem](https://github.com/benchmark-driver/benchmark-drive...
iz (Illia Zub)
01:39 PM Revision 39336c1a (git): [ruby/yarp] Heredocs can create Interpolated(X)StringNodes or
(X)StringNodes
(https://github.com/ruby/yarp/pull/1427)
Prior to this commit, heredocs were automatically InterpolatedNodes
regardless of whether there was actually interpolation. With this
commit, heredocs are only interpolate if there...
jemmai (Jemma Issroff)
01:27 PM Feature #19874 (Closed): Re-introduce heap sort by pinned count prior to GC compaction
See Github PR: [#8420](https://github.com/ruby/ruby/pull/8420)
<hr />
## Introduction
In Ruby 2.7 compaction was originally introduced as an experimental feature.
There was no auto-compaction, and compaction had to be manually ...
eightbitraptor (Matt V-H)
01:11 PM Feature #19790: Optionally write Ruby crash reports into a file rather than STDERR
I've backported @nobu's branch on our 3.2 rubies and it's been working very well. Not too sure what is missing. byroot (Jean Boussier)
01:02 PM Revision b5578557 (git): Restore `in_defined` flag at nested `defined?`
nobu (Nobuyoshi Nakada)
12:11 PM Revision fe3eff08 (git): [ruby/yarp] Move the post required parameters after the rest parameter
* See https://github.com/ruby/yarp/issues/1436
https://github.com/ruby/yarp/commit/6f4e9ff940
Eregon (Benoit Daloze)
11:51 AM Feature #19871 (Rejected): Add __owner__
Eregon (Benoit Daloze)
09:55 AM Feature #19871: Add __owner__
mame (Yusuke Endoh) wrote in #note-2:
> Could you explain the use case?
It's supposed to make sure a general-use module can be implemented purely and can't be tainted by any of its inheritors, unless it's deliberately patched of cour...
konsolebox (K B)
09:47 AM Feature #19871: Add __owner__
nobu (Nobuyoshi Nakada) wrote in #note-3:
> Why not use the constant without scopes?
> ...
I was expecting the lookup to still be affected by the inheriting class. I should have tested it first.
I guess this invalidates the feature...
konsolebox (K B)
06:59 AM Feature #19871: Add __owner__
Why not use the constant without scopes?
```ruby
module M
C = 1234
def m
puts "C: #{C}" #=> C: 1234
end
end
```
nobu (Nobuyoshi Nakada)
06:54 AM Feature #19871: Add __owner__
Could you explain the use case? mame (Yusuke Endoh)
09:31 AM Feature #19839 (Open): Need a method to check if two ranges overlap
Thanks. Basically, we didn't add new methods from ActiveSupport without performance reason.
Can you describe why we should add `overlap?` to ruby core?
hsbt (Hiroshi SHIBATA)
08:54 AM Feature #19839: Need a method to check if two ranges overlap
Though ActiveSupport's `overlaps?` method is enough for our use-case. I think the feature is so fundamental that it should be supported by the standard library.
Slightly off-topic: It might be better to add a method that returns the o...
shouichi (Shouichi Kamiya)
07:53 AM Feature #19839 (Feedback): Need a method to check if two ranges overlap
ActiveSupport already have `overlaps?` method.
* https://api.rubyonrails.org/classes/Range.html#method-i-overlaps-3F
* https://github.com/rails/rails/blob/main/activesupport/lib/active_support/core_ext/range/overlap.rb#L7
Is it en...
hsbt (Hiroshi SHIBATA)
09:08 AM Bug #19844 (Feedback): Ruby 3.2 fails to build with openssl version 3
I'm not sure why you use local installation of OpenSSL 3. I recommend to use libssl provided by Ubuntu 22.04. hsbt (Hiroshi SHIBATA)
08:04 AM Bug #19794 (Assigned): Ruby 3.2.2 fails to build on macOS Sonoma betas
We should avoid to non-existence directory for fresh install of macOS.
@nobu Can you investigate this?
hsbt (Hiroshi SHIBATA)
06:51 AM Bug #19872: TestRequireLib#test_thread_size test case is unstable
Maybe this is becaue the test of `TestRequireLib` does sampling: https://github.com/ruby/ruby/blob/f1c78b23313e63eb31a213cc7277b1eb206a581b/test/ruby/test_require_lib.rb#L13
@znz Should we fix the random seed at least? @nobu says that...
mame (Yusuke Endoh)
06:10 AM Revision f1c78b23 (git): Suppress warning for shadowing outer local variable
hsbt (Hiroshi SHIBATA)
05:23 AM Misc #19858: DevMeeting-2023-09-14
* [Bug #19868] `Process::Status` methods for compatibility with `Fixnum` (nobu)
* Looking at commit:54274b8c65a0981f1c69055a1513ba3c614dd675, noticed that `pst_rshift` contains shift by a negative integer, an unspecified behavior in C9...
nobu (Nobuyoshi Nakada)
04:40 AM Feature #19075: Binary searching for the last element
I think the workaround is good enough. Do you have a good use case to introduce this?
The proposed behavior is not something that can simply be called "last".
The traditional behavior requires a given block to return `false` for elem...
mame (Yusuke Endoh)
03:58 AM Bug #19873 (Closed): Thread#native_thread_id is incorrectly cached across fork on Linux
On Linux, when a process forks, the native thread ID of the (only) thread in the forked child should change.
```
>> libc = Fiddle.dlopen(nil)
=> #<Fiddle::Handle:0x0000ffffb0d8e900>
> ...
=>
#<Fiddle::Function:0x0000ffffb15d1130
...
kjtsanaktsidis (KJ Tsanaktsidis)

09/11/2023

09:49 PM Revision 8953fc77 (git): [ruby/yarp] Provide a flag for the integer base
https://github.com/ruby/yarp/commit/45dd046b83 kddnewton (Kevin Newton)
09:42 PM Revision b7ffa74d (git): [ruby/yarp] Introduce MatchLastLineNode and InterpolatedMatchLastLineNode
These are replacements for regular expressions when they are used
alone as the predicate of a conditional. That's because they are
significantly different from a regular expression because they are
not evaluated for truthyness, but inste...
kddnewton (Kevin Newton)
09:40 PM Revision aa69bd84 (git): Use constant lookup for constant names
kddnewton (Kevin Newton)
09:40 PM Revision bfc82fe1 (git): Remove deprecated aliases from yarp compiler
kddnewton (Kevin Newton)
09:32 PM Revision 14a83e08 (git): [ruby/yarp] Update pretty_print to use inspect
https://github.com/ruby/yarp/commit/c2b9b780c7 kddnewton (Kevin Newton)
09:06 PM Revision 203fdd73 (git): [rubygems/rubygems] Fixed include realpath in error statement
https://github.com/rubygems/rubygems/commit/ac3b85bd5e negi0109
09:06 PM Revision 8bb61077 (git): [rubygems/rubygems] Fixed false positive SymlinkError in symbolic link directory
https://github.com/rubygems/rubygems/commit/58173ff2ea negi0109
05:09 PM Revision 1ae5dd6f (git): Rename `NODE_NEW_TEMPORAL` as `NODE_NEW_INTERNAL`
nobu (Nobuyoshi Nakada)
04:18 PM Revision 719f8344 (git): [ruby/yarp] Mark flags as private
The flags integer is an implementation detail. We want people to
use the query methods to access the individual fields so we are
freed from having to maintain a specific order. As such, this
commit changes the Ruby API to mark all flags ...
kddnewton (Kevin Newton)
03:25 PM Revision 05a853c2 (git): [ruby/yarp] Update fixtures
https://github.com/ruby/yarp/commit/884f2ca8e4 Tim Morgan
03:25 PM Revision 5a8767ed (git): [ruby/yarp] Fix order of Regexp flags
https://github.com/ruby/yarp/commit/e421305ea2 Tim Morgan
03:25 PM Revision 689dffc8 (git): [ruby/yarp] Add failing test for Regexp flags
https://github.com/ruby/yarp/commit/16fe179c5f Tim Morgan
02:09 PM Bug #19872: TestRequireLib#test_thread_size test case is unstable
vo.x (Vit Ondruch) wrote in #note-1:
> Or is it issue of the respective libraries, which does not support proper loading of nested files, without loading their dependencies first?
Randomly looking at lib/reline/history.rb, maybe the ...
vo.x (Vit Ondruch)
02:07 PM Bug #19872: TestRequireLib#test_thread_size test case is unstable
Maybe predefining some well know namespaces could help? Or is it issue of the respective libraries, which does not support proper loading of nested files, without loading their dependencies first? vo.x (Vit Ondruch)
02:05 PM Bug #19872 (Closed): TestRequireLib#test_thread_size test case is unstable
Just exploring the difference in skipped test cases, it seems to be due to `TestRequireLib#test_thread_size`. One test run might look like:
~~~
84) Skipped:
TestRequireLib#test_thread_size:/builddir/build/BUILD/ruby-3.3.0-7c8932365...
vo.x (Vit Ondruch)
03:23 AM Revision b1f0d009 (git): Use the keyword for output and omit default arguments [ci skip]
nobu (Nobuyoshi Nakada)
02:06 AM Revision 05046b89 (git): Add `modencs` target to build encodings/transcoders as modules
nobu (Nobuyoshi Nakada)
02:04 AM Revision 2cc32ad6 (git): Split commit recipe and pass more macros
nobu (Nobuyoshi Nakada)

09/10/2023

03:03 PM Feature #19871: Add __owner__
The changes needed to implement this turned out to be just simple so I went ahead and just created a PR in https://github.com/ruby/ruby/pull/8411.
The difference between using `method(__method__).owner` and using `__owner__` can be de...
konsolebox (K B)
07:58 AM Feature #19871 (Rejected): Add __owner__
Which will give the owner of the currently executing method.
`method(__method__).owner` or `method(__callee__).owner` isn't enough since it may return a different owner if the method is overridden.
Relying on calling the name of it...
konsolebox (K B)
12:56 PM Misc #19870 (Feedback): Why is a long-run thread allocated more memory than a short-run one?
1048936 - 360 = 1048576 = 0x100000
A terminated thread no longer keeps its stack area.
nobu (Nobuyoshi Nakada)
05:56 AM Misc #19870 (Feedback): Why is a long-run thread allocated more memory than a short-run one?
I want to write multithreading programing in Ruby but I found the following memory consumptions.
```
$ irb
irb(main):001> require 'objspace'
=> true
irb(main):002> t1 = Thread.new {}
=> #<Thread:0x00007f9237a74b28 (irb):2 run>
i...
caracal (Taishi Kasuga)
12:37 PM Revision b8d0ab80 (git): Declare `k_class` and `k_module` as `ctxt`
So that it is not ncessary to specify the type each time. nobu (Nobuyoshi Nakada)
10:46 AM Revision 16882d4e (git): Add a new line between function definitions [ci skip]
yui-knk (Kaneko Yuichiro)
10:45 AM Revision b5914a72 (git): Refactor to use same logic with other assignment nodes
yui-knk (Kaneko Yuichiro)
10:39 AM Revision 0e49f817 (git): [DOC] Fix method docs of scheduler#io_read and scheduler#io_write
Each of Fiber::Scheduler#io_read and io_write takes the "offset" as the fourth argument, which is not doucmented. kudojp (Daiki Kudo)
10:33 AM Revision b926ac51 (git): [DOC] Fix a typo in "Open Options" section of IO
The word "and" was missing. herwin (Herwin W)
10:20 AM Revision f2102e40 (git): Set ripper_init.c.tmpl to C mode [ci skip]
nobu (Nobuyoshi Nakada)
 

Also available in: Atom