Project

General

Profile

Activity

From 01/24/2018 to 01/30/2018

01/30/2018

11:55 PM Bug #14425 (Closed): rb_funcall too strict on extra args
Applied in changeset trunk|r62116.
----------
ruby.h: relax rb_funcall check on extra args for clang
clang 5.+ (tested clang 7.0.0) seems to be attempting division-by-zero
and giving a very large number for static args to rb_funcall.
...
Anonymous
09:36 PM Bug #14425 (Closed): rb_funcall too strict on extra args
Ruby 2.5 instroduces extra checking for rb_funcall checking,
but apparently it is too strict for some compilers and extra
args should not cause fatal problems (only warnings).
Jeremy first reported this to me in:
https://bogomips.o...
normalperson (Eric Wong)
11:55 PM Revision e403fd85 (git): * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62117 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
11:55 PM Revision 3ce9a140 (git): ruby.h: relax rb_funcall check on extra args for clang
clang 5.+ (tested clang 7.0.0) seems to be attempting division-by-zero
and giving a very large number for static args to rb_funcall.
* include/ruby/ruby.h (rb_varargs_bad_length): relax check for clang
* ext/-test-/funcall/funcall.c: re...
Eric Wong
07:35 PM Bug #14421 (Closed): super_method segfaults when called on a re-bound Method
Applied in changeset trunk|r62115.
----------
proc: fix super_method segfault after bind
* proc.c: handle undefined iclass
[ruby-core:85231] [Bug #14421]
From: Eric Wong <e@80x24.org>
Anonymous
01:08 AM Bug #14421: super_method segfaults when called on a re-bound Method
andy@rusterholz.org wrote:
> Note: the above failing code correctly returns nil on a coworker's machine
> running `ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-darwin17]`.

Thanks for simple test case, I guess the following pa...
normalperson (Eric Wong)
07:35 PM Revision b10b5122 (git): proc: fix super_method segfault after bind
* proc.c: handle undefined iclass
[ruby-core:85231] [Bug #14421]
From: Eric Wong <e@80x24.org>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Eric Wong
07:19 PM Bug #12941: malloc: *** error for object 0x7fb4a88d2320: pointer being freed was not allocated
No feedback received, no other people have reported the same issue. Let's close this for now until we have a good, isolated repro case. perlun (Per Lundberg)
07:18 PM Feature #14423: Enumerator from single object
> All those conditions are quite different.
Well, you can say that next page fetching "converges" up to "no more pages left" (which in some APIs represented by infinite repetition of the same page, while in other with an empty page), ...
zverok (Victor Shepelev)
02:35 PM Feature #14423: Enumerator from single object
> exit when queue is empty [...] til the result is nil, or same page repeated
All those conditions are quite different. Your reference implementation only handles the latter (`cur == prev`), it doesn't check for `nil`, let alone "queu...
sos4nt (Stefan Schüßler)
09:47 AM Feature #14423 (Closed): Enumerator from single object
**UPD: Current proposal**
Introduce method `Object#enumerate` for producing infinite enumerator by applying block to result of previous call.
Reference implementation:
```ruby
class Object
def enumerate(&block)
Enumerat...
zverok (Victor Shepelev)
06:56 PM Bug #14372: Memory leak in require with Pathnames in the $LOAD_PATH in 2.3/2.4
I opened a backport bug so we can have this memory leak fixed in ruby 2.3 and 2.4:
https://bugs.ruby-lang.org/issues/14424
jrafanie (Joe Rafaniello)
08:27 AM Bug #14372 (Closed): Memory leak in require with Pathnames in the $LOAD_PATH in 2.3/2.4
nobu (Nobuyoshi Nakada)
01:42 AM Bug #14372: Memory leak in require with Pathnames in the $LOAD_PATH in 2.3/2.4
According to `git bisect`, this leak had been introduced at r51360 [Bug #11386] and this was fixed at r59984 [Feature #10222] on trunk. wanabe (_ wanabe)
06:55 PM Bug #14424 (Closed): Backport r59984 to ruby_2_4 and ruby_2_3
Please backport r59984, https://bugs.ruby-lang.org/issues/10222.
There is a memory leak in ruby 2.3 and 2.4 described here: https://bugs.ruby-lang.org/issues/14372
This backport will require backporting other changes to apply thi...
jrafanie (Joe Rafaniello)
06:32 PM Bug #14349 (Closed): Fix Net::HTTP documentation around connection reuse
Applied in changeset trunk|r62113.
----------
net/http: fix documentation for HTTP connection reuse
Thanks to Paul Kuruvilla <rohitpaulk@gmail.com> for the patch
* lib/net/http.rb: fix documentation for HTTP connection reuse
[ruby-c...
Anonymous
06:32 PM Revision 1bb98357 (git): * 2018-01-31
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
06:32 PM Revision 3474d5c3 (git): net/http: fix documentation for HTTP connection reuse
Thanks to Paul Kuruvilla <rohitpaulk@gmail.com> for the patch
* lib/net/http.rb: fix documentation for HTTP connection reuse
[ruby-core:84815] [Bug #14349]
From: Paul Kuruvilla <rohitpaulk@gmail.com>
git-svn-id: svn+ssh://ci.ruby-la...
Eric Wong
06:01 PM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
FYI, I re-ran the examples above (and an additional one) using the `Miller-Rabin`
implementation in my `primes-utls` 3.0 development branch. Not only is it
deterministic up to about 25-digits, but it's way faster too. It can probably...
jzakiya (Jabari Zakiya)
02:56 PM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
How about using part after pid of `Process::Status#inspect`?
```
% ruby -ve 'begin;system(%q(ruby -e "exit(false)"), exception: true);rescue => e;p e;p Process.last_status;end'
ruby 2.6.0dev (2018-01-30 trunk 62111) [x86_64-darwin16...
znz (Kazuhiro NISHIYAMA)
02:41 PM Feature #14411: URI#secure?
- I think scheme is incomplete to detect secure or not.
- postgres scheme use with/without ssl.
- mailto does depend on transport.
- And secure protocols without ssl exist.
- S-HTTP is secure but does not use ssl.
znz (Kazuhiro NISHIYAMA)
01:59 PM Feature #14411: URI#secure?
sos4nt (Stefan Schüßler) wrote:
> artur86 (Artur Beljajev) wrote:
> ...
My fault. I assumed it is immutable, for some reason. Then it will check current scheme dynamically.
artur86 (Artur *)
01:24 PM Feature #14411: URI#secure?
artur86 (Artur Beljajev) wrote:
> Base class might always return false, whereas HTTPS class should return true then.
Note that you can change the scheme:
```ruby
uri = URI('http://example.com/')
uri.scheme = 'https'
uri ...
sos4nt (Stefan Schüßler)
12:37 PM Feature #14411: URI#secure?
`Rack` uses `ssl?`.
https://github.com/rack/rack/blob/master/lib/rack/request.rb#L252
artur86 (Artur *)
12:54 PM Bug #14419 (Closed): SEGV in build - MinGW and/or gcc 7.3.0 svn 62087
nobu (Nobuyoshi Nakada)
04:15 AM Bug #14419: SEGV in build - MinGW and/or gcc 7.3.0 svn 62087
@nobu & @shyouhei
As of svn 62103, Appveyor is green. https://ci.appveyor.com/project/MSP-Greg/ruby-loco/build/396/messages.
Thank you, Greg
MSP-Greg (Greg L)
12:13 PM Revision 1fd4a693 (git): Remove empty directories [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62112 b2dd03c8-39d4-4d8f-98ff-823fe69b080e znz (Kazuhiro NISHIYAMA)
12:03 PM Revision 369b74f8 (git): simply show BASERUBY itself
* common.mk (showflags): simply show `BASERUBY` itself, because nmake does not
supports backquote notation.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62111 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
U.Nakamura
11:50 AM Bug #13628 (Closed): rdoc json.gz files differ across builds
hsbt (Hiroshi SHIBATA)
11:48 AM Feature #14235 (Assigned): Merge MJIT infrastructure with conservative JIT compiler
hsbt (Hiroshi SHIBATA)
11:40 AM Bug #13627 (Closed): created.rid prevents reproducible builds
hsbt (Hiroshi SHIBATA)
11:12 AM Revision 51fdac39 (git): setup.mak: discard BASERUBY output
* win32/setup.mak: discard output from BASERUBY command, even if
it contains multiple commands.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62110 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:46 AM Feature #14362: use BigDecimal instead of Float by default
nobu (Nobuyoshi Nakada) wrote:
> Rational and BigDecimal do not cover irrational numbers.
That's exactly what I wanted to say. Changing Float to BigDecimal only solves _some_ problems. It's not a magic bullet. (neither is Rational)
...
sos4nt (Stefan Schüßler)
10:12 AM Bug #14422: Ruby configuration options should not be reused for gem builds
This sounds very much like fedora-specific problems rather than
a problem caused by ruby, to be honest.
shevegen (Robert A. Heiler)
08:53 AM Bug #14422: Ruby configuration options should not be reused for gem builds
i had some problem when building wxWidgets gem for ruby (and testing it on osx)
i needed to check that both wxWidgets, ruby and my gem where both build with the same compiler,
and in cases of wxWidgets and my gem with same compiler f...
Hanmac (Hans Mackowiak)
08:41 AM Bug #14422: Ruby configuration options should not be reused for gem builds
vo.x (Vit Ondruch) wrote:
> > Our build flags are fully ABI-compatible with each other, so mismatches will not cause any problems at the C/C++/ABI level.
Possibly it can be true on Fedora, but no one guarantees it on other platforms,...
nobu (Nobuyoshi Nakada)
07:15 AM Bug #14422 (Closed): Ruby configuration options should not be reused for gem builds
When Fedora started to harden its packages, we quite often seen complains from our users about problems installing their gems, with errors such as [1]:
~~~
gcc: error: /usr/lib/rpm/redhat/redhat-hardened-cc1: No such file or director...
vo.x (Vit Ondruch)
07:34 AM Revision 42bb73cf (git): support ruby 1.9.3
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e naruse (Yui NARUSE)
07:32 AM Bug #14418: ruby 2.5 slow regexp execution
What happens essentially when using //i is that every 'ß' in the string (and in the regular expression) is expanded to 'ss', dynamically. For [\S\s], this wouldn't be necessary. But all character classes are internally treated the same w... duerst (Martin Dürst)
06:00 AM Bug #14418: ruby 2.5 slow regexp execution
FYI, you can avoid it by using `.` instead of `[\S\s]`. nobu (Nobuyoshi Nakada)
07:08 AM Revision b0d1586f (git): [DOC] Refinements on modules are allowed
From: Leo Correa <lcorr005@gmail.com>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62108 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hsbt (Hiroshi SHIBATA)
06:23 AM Feature #6242: Ruby should support lists
jamesw (James Owen) wrote:
> even i guess so Ruby is a LISP
> ...
Yes agree with you
https://leatherbaba.com/genuine-leather-motorcycle-jacket
huma10 (huma mustqeem)
05:48 AM Bug #14420 (Closed): [BUG] Unnormalized Fixnum value on Rational#hash.to_s
Applied in changeset trunk|r62107.
----------
force fixable
* complex.c (nucomp_hash): force hash values fixable.
[ruby-core:85224] [Bug #14420]
* rational.c (nurat_hash): ditto.
nobu (Nobuyoshi Nakada)
05:48 AM Revision 3f7221ad (git): force fixable
* complex.c (nucomp_hash): force hash values fixable.
[ruby-core:85224] [Bug #14420]
* rational.c (nurat_hash): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62107 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
05:43 AM Revision 5af43b1e (git): ia64: update ia64-specific code to use execution context
This change follows commit 837fd5e494731d7d44786f29e7d6e8c27029806f
in '#ifdef __ia64' branches.
Noticed as a build failure by John Paul Adrian Glaubitz:
```
cont.c:502:50: error: 'rb_thread_t {aka struct rb_thread_struct}'
has n...
hsbt (Hiroshi SHIBATA)
05:32 AM Bug #14403 (Closed): Crash and coredump (Stack consistency error) on ruby 2.5.0
nobu (Nobuyoshi Nakada)
05:31 AM Feature #14405 (Assigned): Add base option to Pathname.glob also
nobu (Nobuyoshi Nakada)
04:17 AM Revision c3ce3b47 (git): vcs.rb: checkout the current branch before rebase
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62105 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
03:57 AM Revision d7d2225e (git): common.mk: added minimum dependencies of incs
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62104 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
03:42 AM Bug #14387: Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
mame (Yusuke Endoh) wrote:
> 環境変数 `RUBY_THREAD_MACHINE_STACK_SIZE` に 1048576 とか大きい値を設定してみたら動きますか?
> ...
スレッドといってもメインスレッドしか存在せず、native_thread_create() が呼び出されるわけではないので、残念ながら動作は変化していないようです。
```
/work # ./miniruby test.rb 2>&1|grep lev...
wanabe (_ wanabe)
03:21 AM Revision d4d671f2 (git): bare_instructions.rb: sp_inc is signed
* tool/ruby_vm/models/bare_instructions.rb (predefine_attributes):
`sp_inc` attribute which may return negative values must be
signed `rb_snum_t`, to be signed-expanded at type promotion.
* vm_insnhelper.h (ADJ_SP): removed the work...
nobu (Nobuyoshi Nakada)
02:21 AM Revision 68e2a2e5 (git): skip EINVAL on unsupported platform
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62102 b2dd03c8-39d4-4d8f-98ff-823fe69b080e ko1 (Koichi Sasada)
02:20 AM Revision a24ccfe6 (git): vcs.rb: fix errors
* tool/vcs.rb (DebugSystem#system): fix undefined local variable
error. as system doesn't accept `exception:` option before 2.6,
remove it from `opts`.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62101 b2dd03c8-39d4-4d8f-98ff...
nobu (Nobuyoshi Nakada)
02:08 AM Revision 5ce70a08 (git): iseq.c: internal lvar name
* iseq.c (local_var_name): name internal local variables as `?N`.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62100 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
12:22 AM Bug #14416 (Closed): Net::POPMail methods modify frozen literal when using default arg
Applied in changeset trunk|r62099.
----------
net/pop: make modified strings mutable
Thanks to Michael Zimmerman for the bug report
* lib/net/pop.rb: make modified strings mutable
[ruby-core:85210] [Bug #14416]
* test/net/pop/test_p...
Anonymous
12:22 AM Revision 7830a950 (git): net/pop: make modified strings mutable
Thanks to Michael Zimmerman for the bug report
* lib/net/pop.rb: make modified strings mutable
[ruby-core:85210] [Bug #14416]
* test/net/pop/test_pop.rb: new test
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62099 b2dd03c8-39d4-...
Eric Wong

01/29/2018

11:41 PM Bug #14416: Net::POPMail methods modify frozen literal when using default arg
mzimme@gmail.com wrote:
> Net::POPMail #pop, #top, and #header can modify their "dest" argument. Problem is it has a default value of '', and so FrozenError can be thrown.

Thanks, will fix.
normalperson (Eric Wong)
05:45 AM Bug #14416 (Closed): Net::POPMail methods modify frozen literal when using default arg
Net::POPMail #pop, #top, and #header can modify their "dest" argument. Problem is it has a default value of '', and so FrozenError can be thrown.
Problem methods start here:
https://github.com/ruby/ruby/blob/582951e2c8995d6bab5ddaf98...
Mzim (Michael Zimmerman)
10:35 PM Feature #14411: URI#secure?
Would this predicate (whatever it's called) return true for an sftp URI? XMPP?
If so, do you not still have to test for HTTP(S) explicitly? So what value does it add?
And if not, don't you just want an `#is_https?` predicate?
phluid61 (Matthew Kerwin)
04:52 PM Feature #14411: URI#secure?
I agree that `#secure?` might not be good for existing `Net::*` classes, but how about `URI`? Do you still think it should also be called `use_ssl?`? I am happy with both of the options, but I wonder how is usually this kind of debates s... artur86 (Artur *)
01:27 AM Feature #14411: URI#secure?
`#use_ssl?` will answer what it is being asked, namely whether SSL is used or not. Aliasing that to `#secure?` will give the wrong impression; there are many different ways to use SSL and still not be 'secure'. So please avoid method nam... duerst (Martin Dürst)
10:32 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
sam.saffron@gmail.com wrote:
> I like ThreadTask a lot since these things are coupled with
> threads. I think ThreadJob works as well.

Maybe we can call it what it is: Thread::Green

I suspect using top-level namespace is unnec...
normalperson (Eric Wong)
09:28 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
I think Routine is a bit tricky to spell so I would recommend avoiding it. In Go people talk about Goroutines but never actually write it in code. That said, this is pretty hidden.
> In other words, API for usage and class name can b...
sam.saffron (Sam Saffron)
08:56 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Looking at naming in few languages that implement a similar feature, there seems to be no consensus:
* Goroutine (Go)
* Lane (Lua)
* Spark on a Haskell Thread (Haskell)
* Task (Elixir - though there's more is going on here, and Pro...
shan (Shannon Skipper)
09:51 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
sam.saffron@gmail.com wrote:
> I like Task a lot, it is short and makes much sense.

I guess there's a risk of namespace conflict with existing
code with such a generic name like "Task" or "Job". But,
maybe the class name should ...
normalperson (Eric Wong)
05:38 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
What about Job?
```
job = Thread.current.queue do
sleep 100
end
job.cancel
```
sam.saffron (Sam Saffron)
05:21 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
On 2018/01/29 14:06, sam.saffron@gmail.com wrote:
> I like Task a lot, it is short and makes much sense.

I strongly oppose the name `Task` because it is ambiguous, many language
(and OSs) uses this word as many purpose.

--
//...
ko1 (Koichi Sasada)
05:06 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
I like Task a lot, it is short and makes much sense.
So conceptually a kernel thread will be allowed to schedule N Tasks.
How would you manage scheduling tasks that are potentially blocking. Should Ruby opt for a goroutine type i...
sam.saffron (Sam Saffron)
04:51 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
sam.saffron@gmail.com wrote:
> I am not a huge fan of the name threadlet, it just does not sound right.

Is "Task" better? Or "CoThread" (like "coroutine").
Actually I don't like "CoThread" much, but "Task" is
short and a somewh...
normalperson (Eric Wong)
12:39 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
I am not a huge fan of the name threadlet, it just does not sound right.
What if a new construct is introduced:
```
pool = ThreadPool.new(concurrency: 100, max_workers: 5 # optional)
thread = pool.run do
sleep # thread pool...
sam.saffron (Sam Saffron)
10:30 PM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
Thank you for taking this project into consideration.
FYI, there is C open source code for both the `Coreutils` [factor](https://github.com/coreutils/coreutils/blob/master/src/factor.c) function and the [APR-CL](https://sourceforge.ne...
jzakiya (Jabari Zakiya)
06:21 AM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
Faster is better -- with certain conditions. Considering those conditions, I would like to take the following approach.
1. Remove the dependency from `mathn.rb` to `prime.rb`
2. Move `prime.rb` from `lib/` to a bundled gem
3. Apply...
yugui (Yuki Sonoda)
08:33 PM Bug #14380 (Open): Expected transform_keys! to work just as transform_keys, but it doesn't
I raised this issue previously https://bugs.ruby-lang.org/issues/13583#note-8
This is a spec change. Moreover it introduces incompatibilities with ActiveSupport.
Matz: final verdict please?
marcandre (Marc-Andre Lafortune)
02:27 PM Bug #14380: Expected transform_keys! to work just as transform_keys, but it doesn't
Will this be backported to 2.5? Eregon (Benoit Daloze)
07:31 PM Bug #14387: Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
~~~ text
/app # ruby -ve 'p RubyVM::DEFAULT_PARAMS[:thread_machine_stack_size]'
ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux-musl]
1048576
/app # RUBY_THREAD_MACHINE_STACK_SIZE=100000 ruby -ve 'p RubyVM::DEFAULT_PARAMS[:thr...
scardon (Daniel Leong)
09:28 AM Bug #14387: Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
wanabe (_ wanabe) wrote:
> koshigoe (Masataka SUZUKI) wrote:
> ...
I've also come across this issue: https://github.com/rspec/rspec-support/pull/343
mame (Yusuke Endoh) wrote:
> 環境変数 `RUBY_THREAD_MACHINE_STACK_SIZE` に 1048576 とか大きい...
craigjbass (Craig Bass)
06:40 PM Bug #14406: File.expand_path doesn't expand tilde inside Windows home directory
I wrote a patch for this with #12656
davispuh (Dāvis Mosāns)
09:38 AM Bug #14406: File.expand_path doesn't expand tilde inside Windows home directory
@abotalov:
you need to call GetLongPathName https://msdn.microsoft.com/en-us/library/windows/desktop/aa364980(v=vs.85).aspx
using win32api or fiddle
the win32api would look like that:
~~~ ruby
require "tmpdir"
def get_long_win3...
Hanmac (Hans Mackowiak)
06:31 PM Bug #14418: ruby 2.5 slow regexp execution
Ok, Blow is the regexp that I tested. I used utf-8 encodnings at the begining:
~~~ ruby
"fußball "*20 =~ /([\S\s]{1000})/i
~~~
Some measurements:
~~~ ruby
(0..20).each { |n| puts Benchmark.measure { "fußball "*n =~ /^([\S\s]...
jakub.wozny (Kuba W)
05:21 PM Bug #14418: ruby 2.5 slow regexp execution
> You have to insert a blank line before
I also often just insert four ' ' space characters before the code
I want to add; no idea if it is correctly interpreted but it seems
to work on both github and ruby-lang.org, so I tend to u...
shevegen (Robert A. Heiler)
04:56 PM Bug #14418: ruby 2.5 slow regexp execution
> I can't paste the code here corectly.
You have to insert a blank line before `~~~`
sos4nt (Stefan Schüßler)
03:25 PM Bug #14418: ruby 2.5 slow regexp execution
I can't paste the code here corectly. I creted a gist with regexp: https://gist.github.com/kubaw/60ca998200d80883156fa94efa7eb6fe jakub.wozny (Kuba W)
03:17 PM Bug #14418 (Closed): ruby 2.5 slow regexp execution
I have simple regexp that performing very slow.
~~~ ruby
"fußball "*20 =~ /^([\S\s]{1000})/i
~~~
It works fast if I remove `/i` flag. I figured out that is also depends on string length or on quantifier value (in this case it is ...
jakub.wozny (Kuba W)
05:54 PM Bug #14421: super_method segfaults when called on a re-bound Method
Note: the above failing code correctly returns nil on a coworker's machine running `ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-darwin17]`. rusterholz (Andy Rusterholz)
05:25 PM Bug #14421 (Closed): super_method segfaults when called on a re-bound Method
The line of code below causes a segfault on 2.5.0.
This appears to possibly be related to #[[11419]], but is not the same.
The segfault is not limited to the String class used in the example; it can be reproduced with any class wit...
rusterholz (Andy Rusterholz)
05:12 PM Revision f65c682f (git): show BASERUBY's version on `make showflags`
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62098 b2dd03c8-39d4-4d8f-98ff-823fe69b080e naruse (Yui NARUSE)
05:05 PM Revision be264f4a (git): Suport ruby 1.9.3
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62097 b2dd03c8-39d4-4d8f-98ff-823fe69b080e naruse (Yui NARUSE)
05:00 PM Bug #14270: backport r61564, r61565, r61571 (fix SEGV touching uninitialized memory)
ruby_2_5 r62095 merged revision(s) 61564,61565,61571. naruse (Yui NARUSE)
05:00 PM Revision 0397ed45 (git): * 2018-01-30
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_5@62096 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
05:00 PM Revision 54a3b8e6 (git): merge revision(s) 61564,61565,61571: [Backport #14270]
fix SEGV touching uninitialized memory
This function can be called from Init_VM().
No assumption can be made about object internals.
(lldb) run
Process 15734 launched: './miniruby' (x86_64)
Proce...
naruse (Yui NARUSE)
04:08 PM Revision 3fa5bd38 (git): Update to ruby/spec@83063a3
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62094 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Eregon (Benoit Daloze)
04:07 PM Revision 1e658d45 (git): * 2018-01-30
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62093 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
04:07 PM Revision 6fd1a18f (git): Update to ruby/mspec@5d49a6c
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Eregon (Benoit Daloze)
04:06 PM Bug #14420: [BUG] Unnormalized Fixnum value on Rational#hash.to_s
The same seems to happen with Complex as well:
https://ci.appveyor.com/project/eregon/windows-shell/build/33
Eregon (Benoit Daloze)
03:57 PM Bug #14420: [BUG] Unnormalized Fixnum value on Rational#hash.to_s
FWIW this was found by ruby/spec: https://github.com/ruby/spec/commit/f30246e5e2909660377a1d7a07591b308595ddab Eregon (Benoit Daloze)
03:56 PM Bug #14420 (Closed): [BUG] Unnormalized Fixnum value on Rational#hash.to_s
~~~ ruby
p eval("(Rational(1, 2)).hash.to_s")
~~~
causes a crash on Windows 64-bit, for both Ruby 2.4 and trunk.
Ruby 2.3 seems fine.
Here is a failure log:
https://ci.appveyor.com/project/eregon/windows-shell
Eregon (Benoit Daloze)
03:41 PM Bug #14419 (Closed): SEGV in build - MinGW and/or gcc 7.3.0 svn 62087
It seems 62087 (https://github.com/ruby/ruby/commit/7d4ad74f22fa259ee81064970fa12d9942472c13) is breaking MinGW builds, which is using gcc 7.3.0.
Failure portion of build log attached.
Thanks, Greg
MSP-Greg (Greg L)
03:17 PM Feature #14417: String#sub / String#gsub に『キーが Symbol の Hash』を渡せるようにする提案
did look at string.c for gsub code,
https://github.com/ruby/ruby/blob/trunk/string.c#L5094
seems to be the line where we could add a transform_keys call
but i don't know currently what the best way to call `hash.transform_keys(&:to_...
Hanmac (Hans Mackowiak)
10:51 AM Feature #14417: String#sub / String#gsub に『キーが Symbol の Hash』を渡せるようにする提案
Thanks for reply!!!
> would it probably better if sub/gsub would call hash.transform_keys(&:to_s) internal in their code with the hash if hash is given?
hmmmm... Thanks for idea :)
> ...
そうですねえ…もう少し具体的なユースケースを考えてみたいと思います。
コメントあ...
osyo (manga osyo)
09:59 AM Feature #14417 (Feedback): String#sub / String#gsub に『キーが Symbol の Hash』を渡せるようにする提案
提案されている利点は弱すぎて賛成しがたいです(趣味では)。
とはいえ機能自体に反対ではないですから、より具体的なユースケースがあると賛成しやすくなるかなと思います。
shyouhei (Shyouhei Urabe)
09:56 AM Feature #14417: String#sub / String#gsub に『キーが Symbol の Hash』を渡せるようにする提案
even if Ruby Symbols are freed now, i still have some problems with that it creates that much symbols from possible tainted string data
would it probably better if sub/gsub would call `hash.transform_keys(&:to_s)` internal in their co...
Hanmac (Hans Mackowiak)
09:35 AM Feature #14417 (Feedback): String#sub / String#gsub に『キーが Symbol の Hash』を渡せるようにする提案
## 概要
`String#sub` / `String#gsub` に『キーが `Symbol` の `Hash`』を渡した場合でも `String` の場合と同様に置き換える。
## 現行の動作
```ruby
hash = {'b'=>'B', 'c'=>'C'}
p "abcabc".gsub(/[bc]/, hash) #=> "aBCaBC"
# キー が Symbol の Hash は置き換えられない
hash =...
osyo (manga osyo)
09:51 AM Misc #14414: Move https://ruby-talk.trydiscourse.com/ to talk.ruby-lang.org
duerst@it.aoyama.ac.jp wrote:
> This is only for ruby-talk at the moment. There are more
> mailing lists on this server; is the idea that all would be
> mirrored, or not?

Fwiw, there's https://public-inbox.org/ruby-core/ and
http...
normalperson (Eric Wong)
05:04 AM Misc #14414: Move https://ruby-talk.trydiscourse.com/ to talk.ruby-lang.org
This is only for ruby-talk at the moment. There are more mailing lists on this server; is the idea that all would be mirrored, or not?
Discourse certainly looks better than the traditional archive at http://blade.nagaokaut.ac.jp/ruby/...
duerst (Martin Dürst)
08:40 AM Revision 552a5a99 (git): string.c (rb_str_format_m): Fix the example code of the doc
Change `%08x` to `%016x` because of two reasons:
* `%016x` demonstrates that we can use two or more digits here.
* Currently, many people uses 64-bit environment.
(I'm unsure if object_id is a good example here, though...)
I'm unsure ...
mame (Yusuke Endoh)
08:11 AM Revision 3bc2f5a9 (git): redefinition of a typedef is a C11ism
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62090 b2dd03c8-39d4-4d8f-98ff-823fe69b080e shyouhei (Shyouhei Urabe)
07:51 AM Bug #14403: Crash and coredump (Stack consistency error) on ruby 2.5.0
It is also reproduce in my environments.
~~~
sw_vers
ProductName: Mac OS X
ProductVersion: 10.12.6
BuildVersion: 16G1212
ruby -v
ruby 2.5.0p0 (2017-12-25 revision 61467) [x86_64-darwin16]
~~~
However, it will not reproduce...
nomotch (kiyoshi nomo)
07:49 AM Feature #6284: Add composition for procs
Please take this to next Developers Meeting Agenda?
The best possible name is discussed for 6 years already, and feature seems pretty nice to have. I believe that sometimes it is just good to make "executive decision" about name once...
zverok (Victor Shepelev)
07:15 AM Revision c788fb48 (git): eliminate CALL_SIMPLE_METHOD
Arrange operands of several opt_something insns so that jumps to
opt_send_without_block can be applied to them. This makes it
possible to eliminate CALL_SIMPLE_METHOD macro at all. Results
in binary size of vm_exec_core to change from 2...
shyouhei (Shyouhei Urabe)
07:04 AM Revision 31ecd18f (git): s/CALL_SIMPLE_METHOD/DISPATCH_ORIGINAL_INSN/
Now that DISPATCH_ORIGINAL_INSN is introduced, we can replace
CALL_SIMPLE_METHOD with DISPATCH_ORIGINAL_INSN. These two macros
differ in size very much and results in this big difference in
compiled binary size. This changeset reduces th...
shyouhei (Shyouhei Urabe)
06:56 AM Revision 7d4ad74f (git): also use sp_inc in vm core
Now that sp_inc attributes are officially provided as inline
functions. Why not use them directly from the vm core, not just
by the compiler. By doing so, it is now possible for us to
optimize stack manipulations. We can now know exactly...
shyouhei (Shyouhei Urabe)
06:54 AM Revision 592dcccd (git): ruby.c: no VARIABLE_LIBPATH
* ruby.c (ruby_init_loadpath_safe): removed code using fixed size
path buffer. relative load path is supported only on platforms
where dladdr is available, or on Windows, so !VARIABLE_LIBPATH
code is not used.
git-svn-id: svn+ssh...
nobu (Nobuyoshi Nakada)
06:47 AM Revision 9a8b38ca (git): extensive use of instruction attributes
Instead of using magic numbers, let us define a series of attributes
and use them from the VM core. Proper function declarations makes
these attributes inlined in most modern compilers. On my machine
exact same binary is generated with...
shyouhei (Shyouhei Urabe)
05:54 AM Feature #14405: Add base option to Pathname.glob also
nobu (Nobuyoshi Nakada) wrote:
> `Pathname` has `glob` instance method.
> ...
Definitely. I also noticed it after created this ticket.
However I think `Pathname.glob` makes sense for two reasons.
Firstly, I think `Pathname.glob...
pocke (Masataka Kuwabara)
05:30 AM Feature #4824: Provide method Kernel#executed?
Hi, i created a patch for this ticket.
please take a look.
https://github.com/ruby/ruby/pull/1802
naofumi-fujii (naofumi fujii)
03:04 AM Bug #14415: Empty keyword hashes get assigned to ordinal args.
Was thinking about this more, and I *think* I see what the problem is: `**` should not be `kwrest`, it should be `options_rest`. And keyword args should be about destructuring the options hash. In the case of mixed keys in the hash, they... josh.cheek (Josh Cheek)
02:17 AM Bug #14413: `-n` and `-p` flags break when stdout is closed
It may be better to translate `Errno::EPIPE` to `SIGPIPE` only in `STDOUT.write`.
```ruby
# silent_epipe.rb
# -*- frozen-string-literal :true -*-
BEGIN {
if Errno.const_defined?("EPIPE") and Signal.list["PIPE"]
class << STD...
nobu (Nobuyoshi Nakada)
01:05 AM Bug #14413: `-n` and `-p` flags break when stdout is closed
It didn't work with `END {}`.
```ruby
# silent_epipe.rb
# -*- frozen-string-literal :true -*-
BEGIN {
if Errno.const_defined?("EPIPE") and Signal.list["PIPE"]
class SystemCallError
prepend Module.new {
sigpi...
nobu (Nobuyoshi Nakada)
12:29 AM Feature #14404: Adding writev support to IO#write_nonblock
> How ugly/tedious would it be for the users to deal with partial
> ...
It does take a bit of work, but I believe the following code would do the job:
~~~ ruby
until chunks.empty?
length = io.write_nonblock(*chunks)
break unle...
janko (Janko Marohnić)

01/28/2018

11:41 PM Feature #13697: [PATCH]: futex based thread primitives
> https://bugs.ruby-lang.org/issues/13697

Note, this may be not as necessary since thread_sync.c stuff
(Mutex/Queue/etc..) no longer use pthread_* primitives
[Feature #13517] [Feature #13552]

... And GVL is a different beast
normalperson (Eric Wong)
10:03 PM Misc #14222: Mutex.lock is not safe inside signal handler: what is?
Definitely needs work, but r62083 is a start for now. normalperson (Eric Wong)
09:57 PM Misc #14222 (Closed): Mutex.lock is not safe inside signal handler: what is?
Applied in changeset trunk|r62083.
----------
doc/signals.rdoc: new document work-in-progress
We need a longer document to inform users of caveats
related to Signal.trap usage. This is still incomplete,
and we can fill in and edit oth...
Anonymous
09:57 PM Revision 582951e2 (git): * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62084 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
09:57 PM Revision ea675ee4 (git): doc/signals.rdoc: new document work-in-progress
We need a longer document to inform users of caveats
related to Signal.trap usage. This is still incomplete,
and we can fill in and edit other bits as needed.
* doc/signals.rdoc: new document
[ruby-core:85107] [Misc #14222]
git-svn-...
Eric Wong
09:46 PM Feature #14399: Add Enumerable#product
According to the thread you provided the initial suggested name was `Array#product_set`
which was shortened to the current `Array#product`. Its proposed intent was to provide
combination groups of set-like items, and not as an arithmet...
jzakiya (Jabari Zakiya)
12:46 AM Feature #14399: Add Enumerable#product
I believe `Enumerable#product` is named after the [Cartesian product](https://en.wikipedia.org/wiki/Cartesian_product) (also called just "product" in set theory). For example, see the discussion in [issue 7444](https://bugs.ruby-lang.org... nate00 (Nate Sullivan)
09:21 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
danieldasilvaferreira@gmail.com wrote:
> normalperson (Eric Wong) wrote:
>
> > No, I'm against making major changes. For 2, I mean we limit
> usage to queues for now, which is a a subset of 1; but I'm also
> OK implementing mutex/...
normalperson (Eric Wong)
08:43 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
normalperson (Eric Wong) wrote:
> No, I'm against making major changes. For 2, I mean we limit
usage to queues for now, which is a a subset of 1; but I'm also
OK implementing mutex/condvar support for 1.
> ...
usefulness
I wou...
dsferreira (Daniel Ferreira)
08:21 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
danieldasilvaferreira@gmail.com wrote:
> ko1 (Koichi Sasada) wrote:
>
> > I'm not sure we should limit to use them on Threadlet or not.
> >
> > 1. Threads and Threadlets can share same synchronization tools
> > -> Good: no l...
normalperson (Eric Wong)
08:03 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Koichi Sasada <ko1@atdot.net> wrote:
> On 2018/01/25 7:01, Eric Wong wrote:
> >For everything else that serves multiple clients in a single
> >process, fair sharing is preferable.
>
> Could you elaborate more? Generally, fairness ...
normalperson (Eric Wong)
05:50 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
ko1 (Koichi Sasada) wrote:
> I'm not sure we should limit to use them on Threadlet or not.
> ...
I'm all for (2) for the reasons I already mentioned:
* Specially the big minus that we have in (1): "People can cause sync issues"
*...
dsferreira (Daniel Ferreira)
02:41 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
On 2018/01/24 2:31, Eric Wong wrote:
>> * Lock and queue should work with auto-fiber?
> I can definitely make Queues work. I think ko1 was mildly
> against increasing use of Mutex.
>
> One safety feature I was thinking about wa...
ko1 (Koichi Sasada)
02:12 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
On 2018/01/25 7:01, Eric Wong wrote:
> For everything else that serves multiple clients in a single
> process, fair sharing is preferable.

Could you elaborate more? Generally, fairness is preferable. But I think
we can document "...
ko1 (Koichi Sasada)
02:08 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
On 2018/01/25 6:51, Eric Wong wrote:
>> Threadlet?
> OK, I am liking "threadlet", and it looks like a real word:
>
> https://www.merriam-webster.com/dictionary/threadlet
> ": a small thread : a delicate filament"
>

Another id...
ko1 (Koichi Sasada)
12:29 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
normalperson (Eric Wong) wrote:
> They should not have a big impact.
Playing the ruby developer role here remember? Do you think most ruby developers don't care about those statements?
What about good and straight forward async gu...
dsferreira (Daniel Ferreira)
11:08 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Eric Wong <normalperson@yhbt.net> wrote:
> > - Matz doesn't have a strong opinion on the name but prefers 2 words (auto-fiber) than a coined word "Thriber."
> >
> > Next actions:
> >
> > * Give a thread-ish name
>
> Threadlet...
normalperson (Eric Wong)
11:08 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
danieldasilvaferreira@gmail.com wrote:
> For all these reasons I would like to propose for the "Light Thread" feature the name:
>
> "Strand"

No, I don't want to introduce a non-obvious term nobody has seen
before in concurrency...
normalperson (Eric Wong)
10:51 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
danieldasilvaferreira@gmail.com wrote:
> When Koichi referring to threads functionality in ruby land writes and says:
>
> > "But most (many? some? a few?) of ruby programmer (including me) can not write correct code I believe."

...
normalperson (Eric Wong)
10:51 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
sam.saffron@gmail.com wrote:
> Hmmm, what about just bringing in the IO Manager APIs
> including Ruby helpers prior to re-introducing the green
> threads?

One big problem I notice with existing IO manager APIs
(libev/libevent/Ev...
normalperson (Eric Wong)
05:20 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Hmmm, what about just bringing in the IO Manager APIs including Ruby helpers prior to re-introducing the green threads?
As it stands kqueue/epoll abstractions always require another fat dependency and there is no official API to cons...
sam.saffron (Sam Saffron)
12:33 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
normalperson (Eric Wong) wrote:
> How about we use Threadlet
IMO the name we will chose will be more important then the functionality in itself.
It needs to stand out and create a clear picture in our mind.
Thread, Fiber, Guild? ...
dsferreira (Daniel Ferreira)
12:02 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
jeremyevans0 (Jeremy Evans) wrote:
> we should be careful to never sacrifice ruby's core values
I couldn't agree more.
> ...
Yes I do Jeremy.
Eric's light thread it was a good starting point for this discussion but I will pres...
dsferreira (Daniel Ferreira)
09:21 PM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
Also, FYI, to go along with using `Integer.sqrt`, you can save some code (and increase performance)
using the [OpenSSL library] (https://ruby-doc.org/stdlib-2.5.0/libdoc/openssl/rdoc/OpenSSL/BN.html), which already has some of the meth...
jzakiya (Jabari Zakiya)
09:11 PM Feature #14410: Reduce allocations and retained objects in the uri common module
sam.saffron@gmail.com wrote:
> I went with the atomic version here cause there is a giant string Hash and it is way cleaner to apply it to the entire file then work through every string in the Hash

Thanks, I looked over it again an...
normalperson (Eric Wong)
09:07 PM Feature #14410 (Closed): Reduce allocations and retained objects in the uri common module
Applied in changeset trunk|r62081.
----------
uri/common: reduce allocations and retained objects
Thanks to Sam Saffron for this patch, it shows
a nice reduction which affects many web applications:
require 'memory_profiler'
Memo...
Anonymous
09:07 PM Revision 823926f4 (git): * 2018-01-29
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
09:07 PM Revision 26b3dc49 (git): uri/common: reduce allocations and retained objects
Thanks to Sam Saffron for this patch, it shows
a nice reduction which affects many web applications:
require 'memory_profiler'
MemoryProfiler.report do
require 'uri'
end.pretty_print
Before:
Total allocated: 986643 bytes (1...
Eric Wong
07:51 PM Feature #14370: Directly mark instruction operands and avoid mark_ary usage on rb_iseq_constant_body
ko1@atdot.net wrote:
> It seems many extra data we are holding. If we shrink such
> extra space (capa) just after compiling, it can reduce memory.

Yes, I think we can resize capa anyways in other places,
perhaps rb_ary_freeze, sin...
normalperson (Eric Wong)
01:43 PM Feature #14370: Directly mark instruction operands and avoid mark_ary usage on rb_iseq_constant_body
> Approximately 60% of the instruction sequences have 0 markable objects. Those 60% account for 35% of the total iseq_encoded that needs to be walked:
Interesting.
Just an idea. Now we allocate Array with extra area and the size of...
ko1 (Koichi Sasada)
06:40 PM Bug #14372: Memory leak in require with Pathnames in the $LOAD_PATH in 2.3/2.4
jrafanie (Joe Rafaniello) wrote:
> it's a fairly common for developers to use Rails.root.join("lib") or something similar in their autoload_paths or eager_load_paths, both of which end up in the $LOAD_PATH and lead to a leak on each ca...
oliverguenther (Oliver Günther)
03:57 PM Bug #14413: `-n` and `-p` flags break when stdout is closed
nobu (Nobuyoshi Nakada) wrote:
> A patch to exit with SIGPIPE when `EPIPE` if `-n` or `-p` option is given.
❤️ ♥️ 💜
josh.cheek (Josh Cheek)
02:48 PM Bug #14413: `-n` and `-p` flags break when stdout is closed
A patch to exit with SIGPIPE when `EPIPE` if `-n` or `-p` option is given.
```diff
diff --git i/error.c w/error.c
index 7cbbf101e0..2f454d01da 100644
--- i/error.c
+++ w/error.c
@@ -53,6 +53,7 @@ int rb_str_end_with_asciichar(VAL...
nobu (Nobuyoshi Nakada)
01:08 PM Bug #14413 (Feedback): `-n` and `-p` flags break when stdout is closed
In common, `SIGPIPE` will terminate the process printing to closed pipe.
And few programs "exit successfully" in such case.
```
$ yes | cat | head -1; echo ${PIPESTATUS[@]}
y
141 141 0
$ yes | grep ^ | head -1; echo ${PIPESTAT...
nobu (Nobuyoshi Nakada)
01:46 AM Bug #14413: `-n` and `-p` flags break when stdout is closed
Actually, maybe it should choose this behavior when `-e` is passed, as well. I often use `-e`, standalone. Here's a video from just a week ago where I used it to filter output (though, as I watch it now, I realized I could have done the ... josh.cheek (Josh Cheek)
01:35 AM Bug #14413 (Closed): `-n` and `-p` flags break when stdout is closed
Ruby generally works well within a pipeline. The `-n` and `-p` flags are incredibly useful. However, it is common practice to use programs like `head` and `sed`, which will close the pipe after completing their job. This is convenient, b... josh.cheek (Josh Cheek)
02:16 PM Revision 2e126959 (git): method.h: VM_METHOD_TYPE_MINIMUM_BITS
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
02:15 PM Feature #14411: URI#secure?
`#secure?` looks more concise and abstract to me, whereas `#use_ssl?` is good in terms of consistency. Perhaps `#secure?` might be aliased to `#use_ssl` in other `Net` classes? artur86 (Artur *)
12:48 PM Feature #14411: URI#secure?
`Net::HTTP` and `Net::POP` have `#use_ssl?` method.
Shouldn't `URI` libraries follow them?
nobu (Nobuyoshi Nakada)
02:05 PM Revision c0d22698 (git): parse.y (parser_append_options): shorter alias LOC
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
12:51 PM Feature #14412 (Assigned): DRb UNIX on local machine: add support for getpeereid()
nobu (Nobuyoshi Nakada)
12:40 PM Bug #14415 (Closed): Empty keyword hashes get assigned to ordinal args.
Spreading empty arrays works, even when they go through a variable, or are disguised:
~~~ruby
args = [] # => []
->{}.call *[] # => nil
->{}.call *args # => nil
->{}.call *([]) # => nil
->{}.call *([];) ...
josh.cheek (Josh Cheek)
10:35 AM Revision e47da4dd (git): method.h: BITFIELD in rb_method_definition_t
* method.h (rb_method_definition_struct): use BITFIELD for
rb_method_type_t.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
05:27 AM Misc #14414 (Rejected): Move https://ruby-talk.trydiscourse.com/ to talk.ruby-lang.org
We created a **read only** mirror of the ruby talk mailing list at:
https://ruby-talk.trydiscourse.com/
I would like this moved under the ruby-lang.org domain and to make it official (and linked from ruby-lang.org).
As it stan...
sam.saffron (Sam Saffron)

01/27/2018

11:34 PM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
dsferreira (Daniel Ferreira) wrote:
> We need to create the foundations for a post ruby 3 future in ruby land where async is the standard for the many and not the exception for the few.
> ...
According to the tagline on the homepage, r...
jeremyevans0 (Jeremy Evans)
03:45 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
normalperson (Eric Wong) wrote:
> I'm not sure what you're talking about. I suppose nothing is reliable
Let me try to explain what I think about the async subject in ruby land using a different story:
For me there is ruby core a...
dsferreira (Daniel Ferreira)
01:17 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
hsbt (Hiroshi SHIBATA) wrote:
> I've restored missing comments on redmine
Thank you very much Hiroshi.
Feels much better now.
dsferreira (Daniel Ferreira)
01:08 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
normalperson (Eric Wong) wrote:
> Daniel Ferreira <subtileos@gmail.com> wrote:
> ...
Hi, I've restored missing comments on redmine from our mailing list.
It's affected by server maintenance and has some issues with server configuratio...
hsbt (Hiroshi SHIBATA)
01:02 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Daniel Ferreira <subtileos@gmail.com> wrote:
> Please try to do something about it because the conversation will be
> lost in the future if nothing is done on that respect.

I've contacted @hsbt about it, be patient as he is busy.
normalperson (Eric Wong)
01:02 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Hi Eric,

It is really a shame that your replies in this thread are not being
added to the issue tracker.
Samuel's reply is there but your reply once again didn't get in.

Please try to do something about it because the conversati...
subtileos (Daniel Ferreira)
01:02 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
samuel@oriontransfer.org wrote:
> In async, I called it `Async::Task`. I think task is a good
> name for this kind of thing. In your case, you might want to
> consider `Thread::Task`. Since, the lexicographic nesting is
> similar to...
normalperson (Eric Wong)
12:58 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Eric Wong <normalperson@yhbt.net> wrote:

> These two?

Yes Eric. And the last one as well. And I guess this here that I will
send will happen the same.
I believe it will be better to not reply to way while this is broken.
Which ...
subtileos (Daniel Ferreira)
12:58 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
danieldasilvaferreira@gmail.com wrote:
> Hi Eric,
>
> I've been reading this issue and I'm finding it fascinating.
> Let me play here the role of the ruby developer that is seeking to
> understand better the asynchronous ruby capa...
normalperson (Eric Wong)
12:57 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Hi Eric,

I've been reading this issue and I'm finding it fascinating.
Let me play here the role of the ruby developer that is seeking to
understand better the asynchronous ruby capabilities.
Every time I read threads(conversations...
subtileos (Daniel Ferreira)
12:56 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
> Thinking about this even more; I don't think it's possible to
> preserve round-robin recv_io/accept behavior I want from
> blocking on native threads when sharing descriptors between
> multiple processes.

```
The following exam...
normalperson (Eric Wong)
12:56 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Eric Wong <normalperson@yhbt.net> wrote:
> hsbt@ruby-lang.org wrote:
> > - Name this "Thread", or something Thread-ish word than Fiber-ish
>
> So if we just use "Thread", then existing Thread becomes M:N?
> I will think about that...
normalperson (Eric Wong)
09:51 PM Feature #14410: Reduce allocations and retained objects in the uri common module
Yes, tests appear to be passing.
I went with the atomic version here cause there is a giant string Hash and it is way cleaner to apply it to the entire file then work through every string in the Hash
sam.saffron (Sam Saffron)
08:31 AM Feature #14410: Reduce allocations and retained objects in the uri common module
sam.saffron@gmail.com wrote:
> https://bugs.ruby-lang.org/issues/14410
> https://github.com/ruby/ruby/pull/1801
> diff.txt (1.03 KB)

Careful with "frozen_string_literal: true".

Even with tired eyes I see self.decode_www_form us...
normalperson (Eric Wong)
07:27 AM Feature #14410 (Closed): Reduce allocations and retained objects in the uri common module
Patch at:
https://github.com/ruby/ruby/pull/1801
require 'memory_profiler'
MemoryProfiler.report do
require 'uri'
end.pretty_print
Before:
Total allocated: 986643 bytes (15159 objects)
Total retained: 246370 bytes ...
sam.saffron (Sam Saffron)
09:04 PM Misc #14395 (Closed): [PATCH] internal.h: add BITFIELD macro
Applied in changeset trunk|r62077.
----------
internal.h: add BITFIELD macro to aid C99 users
I plan to use this macro to pack other enums in the VM.
* internal.h: add BITFIELD macro
* method.h: use BITFIELD for rb_method_visibility_t...
Anonymous
09:04 PM Revision 46bfa65f (git): internal.h: add BITFIELD macro to aid C99 users
I plan to use this macro to pack other enums in the VM.
* internal.h: add BITFIELD macro
* method.h: use BITFIELD for rb_method_visibility_t
[ruby-core:85074] [Misc #14395]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62077 b2dd...
Eric Wong
09:04 PM Revision 6cf78f0e (git): * 2018-01-28
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62076 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
09:04 PM Revision 72b7bd0a (git): vm_core: use "int" for living_thread_num
We treat this as "int" through the vm_living_thread_num API
anyways, and "pid_t" is still 32-bits with glibc on 64-bit
platforms. I expect it'll be a long time before anybody needs
more than 2 billion native threads. For now, let's sav...
Eric Wong
08:30 PM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
Hi Yusuke.
Ah, we agree, `prime.rb` is not conducive for doing heavy-duty math. :-)
Please look at and play with my [primes-utils](https://github.com/jzakiya/primes-utils) gem.
It has a minimal universal useful set of methods for ...
jzakiya (Jabari Zakiya)
05:26 PM Feature #14412 (Assigned): DRb UNIX on local machine: add support for getpeereid()
Hi,
`UNIXSocket` has this method `#getpeereid()` which returns effective user ID and effective group ID.
DRb using `drbunix://` on local machine doesn't support that method. In my use case, I need to verify clients via that method....
Anonymous
03:26 PM Feature #14411: URI#secure?
Thank you for your feedback, Robert! You got it absolutely right in terms of implementation. Base class might always return false, whereas HTTPS class should return true then.
I would be happy to implement it.
artur86 (Artur *)
03:03 PM Feature #14411: URI#secure?
I think this may be a good suggestion, assuming that there is no simpler
API.
The examples on stackoverflow seem very verbose which is often not a
good sign - either the documentation is not good so people can not
find a shorter va...
shevegen (Robert A. Heiler)
02:52 PM Feature #14411 (Open): URI#secure?
I wonder if some predicate method (say #secure?) could be added to URI::Generic class. Currently the only way to query if uri is secure is:
~~~ ruby
uri.instance_of?(URI::HTTPS)
~~~
Inspired by this question: https://stackoverflo...
artur86 (Artur *)
01:55 PM Bug #14409: インストール手順の改善
`Pathname#to_path` は1.9.3以降ですね。
また、autoconfやrubyが必要になるのはrepositoryから直接作る場合なので、tarballから作る場合では必要な手順が変わります。
その点も明確にしたほうがいいでしょう。
nobu (Nobuyoshi Nakada)
07:45 AM Bug #14409: インストール手順の改善
desription のフォーマットがおかしかったのを修正しました。 okkez (okkez _)
06:40 AM Bug #14409: インストール手順の改善
Ruby1.8.7で./configureの実行結果
```
checking for ruby... /usr/bin/ruby
downloading config.guess ... done
tool/downloader.rb:212:in `download': failed to download config.guess (RuntimeError)
NoMethodError: undefined method `to_path' for...
Reetok (Reetok Nino)
06:22 AM Bug #14409 (Closed): インストール手順の改善
以下の2つのインストール手順の部分を改善した方が良いと思いました。
1. `./configure`の生成に必要なautoconfのバージョンを指定するべき
- 2.68以降
2. config.hとMakefileの生成に必要なRubyのバージョンを指定するべき
- 少なくともto_pathが実装されているバージョン
## 環境
```
$ cat /etc/redhat-release
CentOS release 6.8...
Reetok (Reetok Nino)
01:50 PM Revision 6cb01267 (git): insns.def: [DOC] update supported attributes [ci skip]
which are changed at r62051.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62074 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
10:41 AM Bug #14374 (Closed): `for` does not splat elements
Applied in changeset trunk|r62073.
----------
compile.c: try to convert in massign `for`
* compile.c (compile_for_masgn): try to convert to an Array if an
element of massign `for` is not an Array.
[ruby-core:84931] [Bug #14374]
nobu (Nobuyoshi Nakada)
10:41 AM Revision 7ea65f9b (git): compile.c: try to convert in massign `for`
* compile.c (compile_for_masgn): try to convert to an Array if an
element of massign `for` is not an Array.
[ruby-core:84931] [Bug #14374]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
09:41 AM Misc #14222: Mutex.lock is not safe inside signal handler: what is?
eregontp@gmail.com wrote:
> I think that would be very helpful and help to discuss possible improvements.
> Also explaining why Mutex is problematic (the signal handler can be run between any 2 lines of code, and Mutex is not re-entra...
normalperson (Eric Wong)
09:27 AM Revision d0fa578c (git): array.c: rb_check_to_array
* array.c (rb_check_to_array): conversion to array by to_a method.
returns nil if not possible.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62072 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
06:29 AM Feature #8977: String#frozen that takes advantage of the deduping
I think this can be closed as complete cause we have `-"test"` now so we can do it. sam.saffron (Sam Saffron)
06:12 AM Bug #14407 (Closed): defined? still returning true for top-level constant when referenced with scope
Applied in changeset trunk|r62071.
----------
defined? returns nil for toplevel constant lookup
* variable.c (rb_const_defined_0): toplevel constant lookup has
been removed, should return nil too.
[ruby-core:85142] [Bug #14407] [Fi...
nobu (Nobuyoshi Nakada)
02:40 AM Bug #14407: defined? still returning true for top-level constant when referenced with scope
Related to https://bugs.ruby-lang.org/issues/11547 grzuy (Gonzalo Rodriguez)
02:32 AM Bug #14407 (Closed): defined? still returning true for top-level constant when referenced with scope
~~~ ruby
class A
end
class B
end
if defined?(A::B)
puts "defined"
puts A::B
else
puts "not defined"
end
~~~
When running this script with ruby 2.5.0 i get:
~~~
defined
Traceback (most recent call last):
...
grzuy (Gonzalo Rodriguez)
06:12 AM Revision 9473f86f (git): defined? returns nil for toplevel constant lookup
* variable.c (rb_const_defined_0): toplevel constant lookup has
been removed, should return nil too.
[ruby-core:85142] [Bug #14407] [Fix GH-1800]
From: Gonzalo <grzuy0@gmail.com>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62...
nobu (Nobuyoshi Nakada)
06:11 AM Revision 17d8433d (git): vcs.rb: prepend DebugSystem to VCS
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
05:59 AM Feature #14405 (Feedback): Add base option to Pathname.glob also
`Pathname` has `glob` instance method.
```ruby
p Pathname('lib').glob('i*.rb', 0) => [#<Pathname:lib/ipaddr.rb>, #<Pathname:lib/irb.rb>]
```
This looks brief enough.
nobu (Nobuyoshi Nakada)
05:46 AM Bug #13990: Remove obsoleted Ruby code from lib/rdoc/ruby_token.rb from 2.3 and 2.4
OK. Thanks. @usa sho-h (Sho Hashimoto)
05:42 AM Bug #13990: Remove obsoleted Ruby code from lib/rdoc/ruby_token.rb from 2.3 and 2.4
Do not reopen it.
Status "Closed" and Backport "REQUIRED" are the signal for backporting.
usa (Usaku NAKAMURA)
05:36 AM Bug #13990: Remove obsoleted Ruby code from lib/rdoc/ruby_token.rb from 2.3 and 2.4
This ticket was closed but 2.3 and 2.4 is not fixed yet.
@hsbt: Should I reopen this ticket?
sho-h (Sho Hashimoto)
05:45 AM Bug #14406 (Rejected): File.expand_path doesn't expand tilde inside Windows home directory
abotalov (Andrei Botalov) wrote:
> TMP environment variable on Windows is set to a name that contains a tilde.
"Containing" doesn't mean "starting with".
> ...
These contain a tilde, but do *not* start with.
nobu (Nobuyoshi Nakada)
05:35 AM Revision 27db7101 (git): vm_insnhelper.c: avoid intermediate array
* vm_insnhelper.c (vm_expandarray): get rid of creating
intermediate Array object when conversion failed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62069 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
05:20 AM Bug #14408 (Closed): Add hash argument description for GC.stat and GC.latest_gc_info document
I want to add hash argument description to GC.stat and GC.latest_gc_info document.
I guess this argument is for avoiding probe effect like ObjectSpace.#count_objects.
* https://docs.ruby-lang.org/en/2.5.0/ObjectSpace.html#method-c-...
sho-h (Sho Hashimoto)
04:29 AM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
That sounds good. k0kubun (Takashi Kokubun)
04:21 AM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
`Process::Status#inspect` includes signaled information, etc.
How about add such information instead of exit status number only in error messages?
examples: https://gist.github.com/znz/b3c081d0e63d87af6402e27f514f2f15
znz (Kazuhiro NISHIYAMA)
04:14 AM Revision fe18a623 (git): bare_instructions.rb: show class name on inspect
as it's helpful for debugging.
I'm not sure what's the good output for RubyVM::TraceInstructions, so I
left it as it is.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62068 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
04:14 AM Revision ef83b306 (git): Fix duplicated HAVE_NAN
And remove redundant `HAVE_*` macros,
and use `USE_RB_*` macros instead.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
znz (Kazuhiro NISHIYAMA)
02:24 AM Bug #14391 (Assigned): Integer#digitsが遅い
akr (Akira Tanaka)
02:04 AM Bug #14391: Integer#digitsが遅い
厳密にいえばこの提案とは独立な話な気もしますが、
base が 2の累乗の場合は乗除算は不要で、
さらに高速に処理できるだろうと思います。
(rb_integer_pack を使える気がする)
akr (Akira Tanaka)
02:14 AM Revision 3e458f15 (git): insns2vm.rb: add missing word to help
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e k0kubun (Takashi Kokubun)
02:14 AM Revision c8e5796f (git): insns2vm.rb: make #generate_parser private
which is only used by #router.
To make it private, we need to stop defining them on top-level.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62065 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
01:59 AM Revision be27efdb (git): dumper.rb: stop getting --destdir option value
via current directory. It's kind of a global state and fragile to
implementation changes in other places, and how the `Dir.getwd` is set
is not obvious from just reading around `RubyVM::Dumper#initialize` if
it depends on the global stat...
k0kubun (Takashi Kokubun)
01:28 AM Revision d678c274 (git): win32/Makefile.sub: fix typo
Other places are using RT_VER. So I guess this is correct.
Currently AppVeyor CI is failing and I want to fix that.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
01:02 AM Feature #14404: Adding writev support to IO#write_nonblock
janko.marohnic@gmail.com wrote:
> Would it be possible to add this feature to IO#write_nonblock
> as well? IO#write_nonblock is used by the HTTP.rb and Socketry
> gems to implement their "write timeout" feature (the same way
> that ...
normalperson (Eric Wong)
12:55 AM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
vmakarov@redhat.com wrote:
> It mean we need a code to find how many CPUs are on the machine.

We can reuse Etc.nprocessors for most systems in ext/etc/etc.c
normalperson (Eric Wong)

01/26/2018

07:07 PM Feature #14405: Add base option to Pathname.glob also
Probably makes sense so people can use either variant by default
depending on their personal preferences.
I personally love "Dir"-related methods; I think Dir[] is probably
the method I use the most in general when I need to find/o...
shevegen (Robert A. Heiler)
02:08 PM Feature #14405 (Closed): Add base option to Pathname.glob also

`Dir.glob` has `base` option since Ruby 2.5.
https://bugs.ruby-lang.org/issues/13056
However `Pathname.glob` does not have the option.
I would like to use `base` option with `Pathname` class.
But I feel `Dir.glob('*.rb', base: 'd...
pocke (Masataka Kuwabara)
05:19 PM Bug #14372: Memory leak in require with Pathnames in the $LOAD_PATH in 2.3/2.4
Because `Rails.root` is a `Pathname`, it's a fairly common for developers to use Rails.root.join("lib") or something similar in their autoload_paths or eager_load_paths, both of which end up in the $LOAD_PATH and lead to a leak on each c... jrafanie (Joe Rafaniello)
04:42 PM Bug #14406: File.expand_path doesn't expand tilde inside Windows home directory
you are wrong it means something different:
~~~ ruby
File.expand_path("~") #=> "C:/Users/h.mackowiak"
~~~
you thing are FAT paths which got that shortage because of "8.3 filename"
https://en.wikipedia.org/wiki/8.3_filename
ru...
Hanmac (Hans Mackowiak)
04:29 PM Bug #14406 (Rejected): File.expand_path doesn't expand tilde inside Windows home directory
TMP environment variable on Windows is set to a name that contains a tilde. `File.expand_path` doesn't currently return an expanded name. I would expect it to do so as its documentation says:
"Converts a pathname to an absolute pathname...
abotalov (Andrei Botalov)
04:38 PM Revision 7561f7e3 (git): * 2018-01-27
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62062 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
04:38 PM Revision d2bd7d7b (git): need to declare the prototype of nan() if missing
* include/ruby/missing.h (nan): need to declare the prototype of nan() if
missing.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
U.Nakamura
01:38 PM Revision 78c81718 (git): vcs.rb: old version cannot refine modules
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
01:34 PM Revision eab10990 (git): vcs.rb: dcommit for each commit
svn to git bridge on ci.ruby-lang.org sometimes stalls when
dcommitting some commits at once.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62059 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
01:27 PM Revision e168963d (git): vcs.rb: debug print in system method
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62058 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
11:23 AM Feature #13527: Accept IO object as stdin data in Open3.capture
Thank you for the patch!
Since IO.copy_stream also accepts IO objects that respond only to #read (and not #readpartial), would it be possible to also permit those objects as :stdin_data (maybe check that the object responds to either ...
janko (Janko Marohnić)
11:12 AM Feature #14404 (Open): Adding writev support to IO#write_nonblock
In Ruby 2.5 IO#write received writev support (https://github.com/ruby/ruby/commit/3efa7126e5e853f06cdd78d4d88837aeb72a9a3e), allowing it to accept multiple arguments and utilize writev when available.
Would it be possible to add this ...
janko (Janko Marohnić)
10:55 AM Revision c30aed08 (git): error.c: receiver kwarg
* error.c (name_err_initialize_options): NameError#initialize
accepts receiver. [Feature #14313]
* error.c (nometh_err_initialize_options): pass keyword arguments
to the super method.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/tr...
nobu (Nobuyoshi Nakada)
10:55 AM Revision f79d891a (git): test_exception.rb: NameError.new NoMethodError.new
* test/ruby/test_exception.rb: added tests for NameError.new, and
NoMethodError.new including priv argument.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62056 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:55 AM Revision 97d9be79 (git): error.c: [DOC] NoMethodError.new [ci skip]
* error.c (nometh_err_initialize): [RDOC] added missing optional
argument priv.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:55 AM Revision 98c88786 (git): error.c: copy keyword arguments
* error.c (rb_key_err_new): pass arguments all arguments to the
super method, except for keyword arguments copied to instance
variables. [Feature #14313]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62054 b2dd03c8-39d4-4d8f-98...
nobu (Nobuyoshi Nakada)
10:16 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
In async, I called it `Async::Task`. I think task is a good name for this kind of thing. In your case, you might want to consider `Thread::Task`. Since, the lexicographic nesting is similar to the logical nesting.
Regarding kqueue bug...
ioquatix (Samuel Williams)
06:41 AM Revision ba4aba0d (git): error.c: KeyError missing keyword arguments
* error.c (key_err_initialize): leave attributes for missing
keyword arguments unset, so accessors can tell if it is missing
or explicit nil. [Feature #14313]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62053 b2dd03c8-39d4-4d...
nobu (Nobuyoshi Nakada)
06:30 AM Revision 6b61e99e (git): treat PC for gc events
ADD_PCs moved. That didn't change vast majority of event hooks
because vm_traece() has been placed before ADD_PC. However for GC
events the situation is different. We have to take care.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@...
shyouhei (Shyouhei Urabe)
06:30 AM Revision 3234245a (git): move ADD_PC around to optimize PC manipluiations
This commit introduces new attribute handles_flame and if that is
_not_ the case, places ADD_PC right after INC_SP. This improves
locality of PC manipulations to prevents unnecessary register spill-
outs. As a result, it reduces the siz...
shyouhei (Shyouhei Urabe)
05:38 AM Feature #14313: Support creating KeyError with receiver and key from Ruby
Shouldn't unspecified attribute raise an exception?
```diff
diff --git c/error.c i/error.c
index 990f9f7855..7870e58035 100644
--- c/error.c
+++ i/error.c
@@ -1692,8 +1692,6 @@ key_err_initialize(int argc, VALUE *argv, VALUE self...
nobu (Nobuyoshi Nakada)
04:51 AM Feature #14313 (Closed): Support creating KeyError with receiver and key from Ruby
Applied in changeset trunk|r62049.
----------
KeyError#initialize accepts receiver and key.
[Feature #14313][ruby-core:84626]
kou (Kouhei Sutou)
05:34 AM Revision b56f6a6b (git): error.c: use already initialized IDs
[Feature #14313]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62050 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
04:51 AM Revision cd83d267 (git): KeyError#initialize accepts receiver and key.
[Feature #14313][ruby-core:84626]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62049 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Sutou Kouhei
04:03 AM Feature #4938: Add Random.bytes [patch]
Updated.
```diff
diff --git i/random.c w/random.c
index 43a3d2ffee..b800f1d9a1 100644
--- i/random.c
+++ w/random.c
@@ -1134,6 +1134,19 @@ rb_random_bytes(VALUE obj, long n)
return genrand_bytes(rnd, n);
}

+/*
+ * ca...
nobu (Nobuyoshi Nakada)
03:54 AM Revision 4fb218f9 (git): Removed workaround Travis CI.
Revert r61209, r61210
From: SHIBATA Hiroshi <hsbt@ruby-lang.org>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62048 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hsbt (Hiroshi SHIBATA)
03:41 AM Revision db1de35a (git): optparse.rb: froze string literals
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
03:38 AM Bug #14387: Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
環境変数 `RUBY_THREAD_MACHINE_STACK_SIZE` に 1048576 とか大きい値を設定してみたら動きますか?
これで pthread_attr_setstacksize に渡すスタックサイズを調整できます。
なお、この設定は RubyVM::DEFAULT_PARAMS で読み出すことができます。
```
$ ruby -ve 'p RubyVM::DEFAULT_PARAMS[:thread_machine_stack_si...
mame (Yusuke Endoh)
02:54 AM Bug #14387: Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
https://qiita.com/koshigoe/items/7acebbab7b44fa2b35bc
This is the post that spin off this issue ticket.
There are more information in there.
Hope we could get some form of resolution for Alpine users.
scardon (Daniel Leong)
03:13 AM Revision f3668844 (git): ignore external library sources [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
03:13 AM Revision acdc2f09 (git): ext/psych/.gitignore: removed stale file [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
02:22 AM Feature #14223: Refinements で定義した #to_proc が &hoge 時に呼ばれないのを緩和する提案
ありがとうございます! osyo (manga osyo)
02:01 AM Revision 9c7caa3b (git): Fix rubyspec against the change in Hash#transform_keys!
[Bug #14380] [ruby-core:84951]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62044 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Kenta Murata
01:33 AM Bug #14380 (Closed): Expected transform_keys! to work just as transform_keys, but it doesn't
Applied in changeset trunk|r62042.
----------
hash.c: support key swapping in Hash#transform_keys!
* hash.c (rb_hash_transform_keys_bang): support key swapping in
Hash#transform_keys!
[Bug #14380] [ruby-core:84951]
* test/ruby/tes...
mrkn (Kenta Murata)
01:33 AM Revision e7c62ca7 (git): * 2018-01-26
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62043 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
01:33 AM Revision 52bb93c2 (git): hash.c: support key swapping in Hash#transform_keys!
* hash.c (rb_hash_transform_keys_bang): support key swapping in
Hash#transform_keys!
[Bug #14380] [ruby-core:84951]
* test/ruby/test_hash.rb (test_transform_keys_bang):
add assertions for this change
git-svn-id: svn+ssh://ci.ruby...
Kenta Murata

01/25/2018

11:53 PM Bug #14402 (Closed): Crash and coredump (Stack consistency error) on ruby 2.5.0
nobu (Nobuyoshi Nakada)
06:07 PM Bug #14402: Crash and coredump (Stack consistency error) on ruby 2.5.0
Sorry accidentally double-reported, the issue tracker gave me an error on first submit and I thought it hadn't been submitted. Close in favor of https://bugs.ruby-lang.org/issues/14403 jrochkind (jonathan rochkind)
04:39 PM Bug #14402 (Closed): Crash and coredump (Stack consistency error) on ruby 2.5.0
This reproduction script seems to make no sense, because it's extracted from an actual program where I encountered this bug, and trimmed down to be the minimal I can get to reproduce.
Parts of the script that seem irrelevant (like th...
jrochkind (jonathan rochkind)
11:02 PM Bug #14387: Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
koshigoe (Masataka SUZUKI) wrote:
> Ruby のバージョンによって、再帰が止められるまでの回数に大きな違いがあるのはなぜでしょうか?
> ...
`git bisect` で確認したところ、 r59630 以降に今の挙動になっているようでした。
r59630 は [Bug #13412] に関連したコミットで、差分を見ると `stack_check(th)` というところから、スレットのスタックをチェックする処理が追加されている...
wanabe (_ wanabe)
10:25 PM Feature #14394: Class.descendants
I think one part of the discussion was that this features requires classes to explicitly track their subclasses (which is a memory overhead, and it must be a list of weak references to avoid leaking subclasses).
I think MRI now tracks s...
Eregon (Benoit Daloze)
09:29 PM Feature #14394: Class.descendants
@Hanmac yeah, registering with a method or a static list is common practice. But I feel like Ruby can do better.
For many cases, it's possible to track them with the inherited hook, @Erogon. But for something so fundamental, why not i...
ridiculous (Ryan Buckley)
02:34 PM Feature #14394: Class.descendants
"Class#inherited hook" works not for core classes because they are defined before you can define the hook
also should that show only named classes or anonymous somehow too?
@ridiculous: i often see a register method where you regis...
Hanmac (Hans Mackowiak)
12:18 PM Feature #14394: Class.descendants
Could that work with just the Class#inherited hook?
What's the advantage of asking all subclasses/descendents of a class instead?
Eregon (Benoit Daloze)
06:41 PM Feature #14399: Add Enumerable#product
That's interesting because I never intuitively understood the use
of `inject`, especially for numerical purposes, and always now use
`reduce`, which was (I believe) created by Haskell (the person and
programming language), and has l...
jzakiya (Jabari Zakiya)
10:42 AM Feature #14399: Add Enumerable#product
> which is a little longer, but I think is more accurately
> ...
We are back to the ancient problem - giving things good names. :-)
The only name from the above that I like is .sum - the others
do not tell me much at all. ;-)
I a...
shevegen (Robert A. Heiler)
01:29 AM Feature #14399: Add Enumerable#product
Actually, after looking at the docs for `Array#product` a
better name would be `Array#combinations`, which is a little
longer, but I think is more accurately descriptive and intuitive.
Oh well, cats out the bag now.
jzakiya (Jabari Zakiya)
01:22 AM Feature #14399: Add Enumerable#product
Duh, ok, its an `Array` method. jzakiya (Jabari Zakiya)
01:20 AM Feature #14399: Add Enumerable#product
I looked here https://ruby-doc.org/core-2.5.0/Enumerable.html and didn't see
that method, so I didn't know it existed. But `multiply` would also work.
Where in the docs is `product`?
The Ruby `product` then causes a conflict with ...
jzakiya (Jabari Zakiya)
12:21 AM Feature #14399: Add Enumerable#product
Array#product would stomp on Enumerable#product, and it confusingly does a different thing:
~~~ ruby
[2,3,5,7].product => [[2], [3], [5], [7]]
~~~
Maybe Enumerable#multiply would compliment Enumerable#sum?
shan (Shannon Skipper)
04:40 PM Bug #14403: Crash and coredump (Stack consistency error) on ruby 2.5.0
Oops, sorry, somehow missed reproduction script in the original report, here it is:
https://gist.github.com/jrochkind/a8344b1805badec8109b6f95c89a745b
```
require 'rexml/parsers/pullparser'
def look_at_record(parser)
# While...
jrochkind (jonathan rochkind)
04:39 PM Bug #14403 (Closed): Crash and coredump (Stack consistency error) on ruby 2.5.0
This reproduction script seems to make no sense, because it's extracted from an actual program where I encountered this bug, and trimmed down to be the minimal I can get to reproduce.
Parts of the script that seem irrelevant (like th...
jrochkind (jonathan rochkind)
04:26 PM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
Your `prime_division2` uses `OpenSSL::BN#prime?`. You may know, it is a Miller-Rabin *probabilistic* primality test which may cause a false positive. In short, I suspect that your code may (very rarely) return a wrong result. Am I rig... mame (Yusuke Endoh)
02:31 PM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
Thanks, Takashi, but very often in my code, when dealing with output and error management of external commands, I end up wrapping them in a utility method of my own to properly handle errors and control flow anyway, so I'm not sure I'm i... rosenfeld (Rodrigo Rosenfeld Rosas)
01:22 PM Revision d00ef6b3 (git): compile.c: check mid
* compile.c (iseq_peephole_optimize): check that method ID is +@.
fix up r62039.
http://d.hatena.ne.jp/nagachika/20180125/ruby_trunk_changes_62025_62039#r62039
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62041 b2dd03c8-39d4-4d...
nobu (Nobuyoshi Nakada)
01:13 PM Feature #14401 (Open): Integer#digitsの逆の動作をするメソッドが欲しい
Integer#digitsの逆の動作をするメソッドがあると良いと思うのですがどうでしょうか?
~~~ruby
inverse_of_digits([5,4,3,2,1]) # => 12345
inverse_of_digits([1,0,1,1], 2) # => 13
inverse_of_digits(num.digits(base), base) == num #=> true
~~~
以下のようなケースで便利です
~~~ruby
...
tompng (tomoya ishida)
01:10 PM Bug #14388 (Closed): 不正エンコーディング文字列から切り出した正当なエンコーディング文字列が invalid encoding になる
Applied in changeset trunk|r62040.
----------
string.c: clear substring code range
* string.c (str_substr): substring of broken code range string may
be valid or broken. patch by tommy (Masahiro Tomita) at
[ruby-dev:50430] [Bug #1...
nobu (Nobuyoshi Nakada)
03:52 AM Bug #14388: 不正エンコーディング文字列から切り出した正当なエンコーディング文字列が invalid encoding になる
Rubyの内部のコードにはあんまり詳しくないんですけど、これで直ると思うのですがどうでしょうか。
```diff
diff --git a/string.c b/string.c
index 82fa603ada..9079387fac 100644
--- a/string.c
+++ b/string.c
@@ -2560,6 +2560,7 @@ str_substr(VALUE str, long beg, long len, int empty...
tommy (Masahiro Tomita)
01:10 PM Revision 9237049e (git): string.c: clear substring code range
* string.c (str_substr): substring of broken code range string may
be valid or broken. patch by tommy (Masahiro Tomita) at
[ruby-dev:50430] [Bug #14388].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62040 b2dd03c8-39d4-4d8f-98...
nobu (Nobuyoshi Nakada)
12:31 PM Feature #13581: Syntax sugar for method reference
@nobu Thanks, I've updated the list.
Can you please add it to next Developer Meeting's agenda?..
zverok (Victor Shepelev)
12:23 PM Feature #13581: Syntax sugar for method reference
zverok (Victor Shepelev) wrote:
> * `map(&Math.>sqrt)`, `each(&.>puts)`
This conflicts with existing syntax.
> ...
Not this.
nobu (Nobuyoshi Nakada)
12:23 PM Feature #14397: public, protected and private should return their arguments instead of self
Would it be simpler for the semantics to always return an Array of symbols?
Otherwise `final` (and other potential uses) has to handle both a single Symbol and an Array of Symbol.
One concern is the extra allocations for the common c...
Eregon (Benoit Daloze)
12:00 PM Revision 845b3cfb (git): compile.c: unnecessary freezing
* compile.c (iseq_peephole_optimize): get rid of freezing
dynamically created string to be duplicated immediately.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62039 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
11:34 AM Bug #14389: Reflected XSS
TheGirdap (Hamit Cibo) wrote:
> hsbt (Hiroshi SHIBATA) wrote:
> ...
I see the message now "https://bugs.ruby-lang.org/issues/14389" ..
TheGirdap (Hamit Cibo)
11:12 AM Bug #14389: Reflected XSS
hsbt (Hiroshi SHIBATA) wrote:
> Thank you for your report.
> ...
gift ?
TheGirdap (Hamit Cibo)
01:46 AM Bug #14389 (Third Party's Issue): Reflected XSS
Thank you for your report.
But I know that you already reported other places and shared the upstream information.
* https://github.com/ruby/www.ruby-lang.org/issues/1734
* https://github.com/ruby/www.ruby-lang.org/issues/1735
...
hsbt (Hiroshi SHIBATA)
11:21 AM Revision 07decad2 (git): openssl/buffering.rb: no RS when output
* ext/openssl/lib/openssl/buffering.rb (do_write, puts): output
methods should not be affected by the input record separator.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:28 AM Bug #14400 (Closed): IO#ungetc and IO#ungetbyte documentation is inconsistent with the behavior
The documentation of IO#ungetc states:
> Pushes back one character (passed as a parameter) onto ios, such that a
> ...
And similar for IO#ungetbyte:
> Pushes back bytes (passed as a parameter) onto ios, such that a
> ...
The part...
Eregon (Benoit Daloze)
10:09 AM Feature #14240: warn four special variables: $; $, $/ $\
I wonder that aliased variables also should be warned, `$-0`, `$-F`, and aliases in English.rb.
Currently, aliases of `$KCODE` are also warned.
In other words, the feature of `$KCODE` is warned (and has no effect now).
Should we w...
nobu (Nobuyoshi Nakada)
10:00 AM Misc #14222: Mutex.lock is not safe inside signal handler: what is?
normalperson (Eric Wong) wrote:
> > Having a not-well defined set of allowed operations in a Ruby block (the signal handler) seems a much larger problem worth fixing.
> ...
I think that would be very helpful and help to discuss possib...
Eregon (Benoit Daloze)
09:55 AM Bug #14375: 3 Spec failures building MinGW 2018-01-19 trunk 61950
Thank you for the report and patches.
I decided to remove the specs trying arbitrary values for chmod/umask in r62036.
So much platform guards is usually a sign we are testing OS/libc-level stuff, which is not really the right thing ...
Eregon (Benoit Daloze)
09:50 AM Bug #14375 (Closed): 3 Spec failures building MinGW 2018-01-19 trunk 61950
Applied in changeset trunk|r62036.
----------
Remove specs trying arbitrary values for chmod and umask
* Instead assert that too large values raise RangeError.
* [Bug #14375] [ruby-core:84933]
* See https://github.com/ruby/ruby/pull/1797
Eregon (Benoit Daloze)
09:50 AM Revision b101d2c2 (git): Group related File.umask specs together
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Eregon (Benoit Daloze)
09:50 AM Revision 7dc0bdb6 (git): Remove specs trying arbitrary values for chmod and umask
* Instead assert that too large values raise RangeError.
* [Bug #14375] [ruby-core:84933]
* See https://github.com/ruby/ruby/pull/1797
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62036 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Eregon (Benoit Daloze)
08:13 AM Feature #14392: Pipe operator
Also when I want to look specifically at the API of a certain class I look into its documentation not the code base. dsferreira (Daniel Ferreira)
08:11 AM Feature #14392: Pipe operator
shyouhei (Shyouhei Urabe) wrote:
> Don't you have difficulties writing elixir code then?
I mentioned already that Elixir it is there only as a reference.
I do not code Elixir.
> ...
The reason I think otherwise is this:
Whe...
dsferreira (Daniel Ferreira)
08:06 AM Feature #14392: Pipe operator
Hanmac (Hans Mackowiak) wrote:
> Symbol#pri and others will never work
You're right. Not to much thought put on that one. It is not so easy as it seems from my comment but I wouldn't say never. When working with ruby "never" is a ...
dsferreira (Daniel Ferreira)
07:36 AM Feature #14392: Pipe operator
dsferreira (Daniel Ferreira) wrote:
> shyouhei (Shyouhei Urabe) wrote:
> ...
To be clear I am not against specifying method visibility.
> Now, why do I require the visibility being set after the method definition?
> ...
Don't you h...
shyouhei (Shyouhei Urabe)
07:35 AM Feature #14392: Pipe operator
Symbol#pri and others will never work because you failed to understand how Object work in ruby
so NO "easily do by extending Symbol class"
----
there is also using them as modifier for the class scope
~~~ruby
class Foo
pr...
Hanmac (Hans Mackowiak)
07:25 AM Feature #14392: Pipe operator
Shyouhei,
To add up to this:
When I look into a specific method my first concern is about the source code not its visibility.
Visibility information it is important but secondary when doing code analysis.
Why? Because I'm totally...
dsferreira (Daniel Ferreira)
07:07 AM Feature #14392: Pipe operator
shyouhei (Shyouhei Urabe) wrote:
> Is it really worth adding a new syntax to replace private def... ?
For me it is Shyouhei.
Like I said before, I care a lot about the visibility of my methods.
The clear definition of each int...
dsferreira (Daniel Ferreira)
06:32 AM Feature #14392: Pipe operator
I don't remember any programming language which puts the visibility of a method at the trailer of a method body. Is it really worth adding a new syntax to replace private def... ? shyouhei (Shyouhei Urabe)
05:49 AM Feature #14392: Pipe operator
mame (Yusuke Endoh) wrote:
> I'm now a bit against the feature
Yusuke what would you propose as an alternative?
Note that my main requirement behind this is to be able to use `private` after the method definition without the ne...
dsferreira (Daniel Ferreira)
02:09 AM Feature #14392: Pipe operator
dsferreira (Daniel Ferreira) wrote:
>
> ...
Well... I was neutral to a pipe operator, but if people overuse (or even abuse) it like this, I'm now a bit against the feature.
mame (Yusuke Endoh)
05:59 AM Feature #14371 (Rejected): New option "recursive: true" for Hash#transform_keys!
I see. Thank you! tagomoris (Satoshi Tagomori)
01:48 AM Revision 429e2abf (git): optparse.rb: literal newline
* lib/optparse.rb (OptionParser#summarize): use literal newline to
join option summaries as IO#puts does, not the special gloval
variable $/.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62035 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
01:15 AM Feature #13618: [PATCH] auto fiber schedule for rb_wait_for_single_fd and rb_waitpid
Hi Eric,
I've been reading this issue and I'm finding it fascinating.
Let me play here the role of the ruby developer that is seeking to
understand better the asynchronous ruby capabilities.
Every time I read threads(conversations)...
dsferreira (Daniel Ferreira)
12:42 AM Revision f8fa8dd9 (git): revert r62032 because it refers to a undefined variable
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62034 b2dd03c8-39d4-4d8f-98ff-823fe69b080e ko1 (Koichi Sasada)
12:11 AM Bug #14246 (Closed): Inconsistent C source code indentation
Applied in changeset trunk|r62033.
----------
.editorconfig: Use spaces instead of tab except Makefiles
ref [Bug #14246]
[ci skip]
Anonymous
12:11 AM Revision 224bbbdc (git): .editorconfig: Use spaces instead of tab except Makefiles
ref [Bug #14246]
[ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62033 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
znz (Kazuhiro NISHIYAMA)

01/24/2018

11:30 PM Feature #14399 (Open): Add Enumerable#product
For similar reasons for creating `Enumerable#sum` a companion method
`Enumerable#product` is also very useful. Taking the product of
numbers in arrays is a common operation in many numerical algorithms,
especially in number theory and...
jzakiya (Jabari Zakiya)
11:17 PM Revision 3010d5ee (git): optparse.rb: literal newline
* lib/optparse.rb (OptionParser#summarize): use literal newline to
join option summaries as IO#puts does, not the special gloval
variable $/.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62032 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:41 PM Feature #14394: Class.descendants
Thanks for the reply, shevegen, those are helpful questions :)
The gems I've seen implement this are active-support and dry-rb, with other people checking ObjectSpace to get the list (which can be very slow for large apps).
The mos...
ridiculous (Ryan Buckley)
09:01 PM Feature #14394: Class.descendants
I do not know if it was suggested before, but it could be discussed
at the ruby developer meeting perhaps (unless it was already rejected).
I think it may be symmetrical to .ancestors too.
To complete your suggestion, could you de...
shevegen (Robert A. Heiler)
07:07 PM Feature #14394 (Assigned): Class.descendants
There have been numerous implementations of the method Class.descendants by various gems. However, I can't help but think that this ability should be included in the Ruby language itself. Especially since Ruby already offers the counterp... ridiculous (Ryan Buckley)
10:41 PM Bug #14398 (Closed): [BUG] Bus Error
Hi Folks, not sure it this is appropriate place to send my bug.
I noticed this error when I tried to apply Puppet manifest https://github.com/kmonticolo/OpenBSD-owncloud-puppet/blob/master/site.pp on OpenBSD 6.2 machine using # puppet a...
kmonticolo (Kamil Monticolo)
10:40 PM Revision 69d6e7d9 (git): vm.c: remove unnecessary branch
th->altstack is never NULL, and even if it were, POSIX
stipulates free(3) on NULL to be a no-op.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62031 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Eric Wong
10:39 PM Revision 7c8b7975 (git): load.c: use fstring instead of OBJ_FREEZE
These strings already exist (or will exist soon) in the fstring
table, so avoid the duplicate, sooner.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62030 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Eric Wong
09:41 PM Feature #14392: Pipe operator
shevegen (Robert A. Heiler) wrote:
> No |> though.
Hi Robert, many thanks for the extensive comment.
The idea of using `"|>"` as the proposed pipe operator came from my analysis of https://bugs.ruby-lang.org/issues/13581 issue c...
dsferreira (Daniel Ferreira)
08:54 PM Feature #14392: Pipe operator
> It will be reject anyways but I will still continue to seek
> ...
Who knows - but I think it may be too difficult to change it at
this point.
When it comes to personal preferences, what may work for you may
not work for others.
...
shevegen (Robert A. Heiler)
04:24 PM Feature #14392: Pipe operator
zverok (Victor Shepelev) wrote:
> That's the way, obviously.
Fortunately not every one look at things the same way, and I believe ruby core allows us to come in and discuss matters.
This is an important matter to me.
I know not m...
dsferreira (Daniel Ferreira)
04:10 PM Feature #14392: Pipe operator
zverok (Victor Shepelev) wrote:
> It already looks messed up :)
Didn't understand very well how messed up it is.
Is that syntax impossible to implement or messed up just because the way ruby people tend to look at code syntax?
...
dsferreira (Daniel Ferreira)
03:16 PM Feature #14392: Pipe operator
>> `private def bar(var)`
> ...
So, what you saying is "I don't like how the consistent set of features in language looks [it can't even be said to be "verbose", man!], so please introduce a new inconsistent feature for me to like it"...
zverok (Victor Shepelev)
03:13 PM Feature #14392: Pipe operator
Let me, then, introduce some philosphy here (I know this issue will be rejected anyways, so whatever).
When you propose new language feature, it is often useful to think a bit of it: how it plays with other features and general langua...
zverok (Victor Shepelev)
02:59 PM Feature #14392: Pipe operator
Hanmac (Hans Mackowiak) wrote:
> `private def bar(var)`
I don't like the syntax it provides.
What I do currently is:
```ruby
class Foo
def bar(var)
puts “Hello #{var}!”
end
private :bar
def baz(arg)
...
dsferreira (Daniel Ferreira)
02:54 PM Feature #14392: Pipe operator
zverok (Victor Shepelev) wrote:
> We already have yield_self (2.5+) exactly for this.
I will not use it like that.
Not for the situations I presented.
To ugly and verbose.
dsferreira (Daniel Ferreira)
02:47 PM Feature #14392: Pipe operator

~~~ ruby
class Foo
private def bar(var)
puts “Hello #{var}!”
end
def baz(arg)
bar(arg)
end
end
~~~
method def already return their method name, so they can be used with private/protected
Hanmac (Hans Mackowiak)
02:43 PM Feature #14392: Pipe operator
We already have `yield_self` (2.5+) exactly for this.
```ruby
class Foo
##
# Bar public method.
def bar(*args)
args.select do { |arg| arg =~ /regex/ }.first
yield_self(&method(:good))
end.yield_self(&meth...
zverok (Victor Shepelev)
02:35 PM Feature #14392 (Open): Pipe operator
I would like to see implemented in ruby a pipe operator as we have in elixir.
An example of application I have in mind is this:
```ruby
class Foo
def bar(var)
puts “Hello #{var}!”
end |> private

def baz(arg)
...
dsferreira (Daniel Ferreira)
09:28 PM Feature #14396 (Rejected): public, protected and private should return their arguments instead of self
誤ってruby-devに投げてしまったのでこっちは閉じます。
[Feature #14397] を参照。
usa (Usaku NAKAMURA)
09:14 PM Feature #14396 (Rejected): public, protected and private should return their arguments instead of self
Matsuda-san suggested me that `public`, `protected` and `private` should return their arguments instead of self,
to write such code:
```Ruby
require "finalist"
# see https://github.com/joker1007/finalist
class Foo
extend Fina...
usa (Usaku NAKAMURA)
09:27 PM Feature #14397 (Assigned): public, protected and private should return their arguments instead of self
Matsuda-san suggested me that `public`, `protected` and `private` should return their arguments instead of `self`,
to write such code:`
```Ruby
require "finalist"
# see https://github.com/joker1007/finalist
class Foo
extend F...
usa (Usaku NAKAMURA)
09:13 PM Bug #14314: Marshalling broken in Ruby 2.5.0 for Structs with keyword_init: true
The YAML issue has also been fixed on trunk. shan (Shannon Skipper)
09:07 PM Misc #14381 (Closed): [PATCH] ruby/ruby.h: remove unnecessary exports from C-API
Applied in changeset trunk|r62029.
----------
ruby/ruby.h: remove unnecessary exports from C-API
Needlessly exporting can reduce performance locally and increase
binary size.
Increasing the footprint of our C-API larger is also detrim...
Anonymous
09:07 PM Revision 7e669f40 (git): ruby/ruby.h: remove unnecessary exports from C-API
Needlessly exporting can reduce performance locally and increase
binary size.
Increasing the footprint of our C-API larger is also detrimental
to our development as it encourages tighter coupling with our
internals; making it harder for...
Eric Wong
08:58 PM Feature #14393: Support sending file descriptors (on local machine) via DRb UNIX
Would be nice.
I must admit that I have not used drb in a really long time - but I
am a firm believer in ruby objects dwelling everywhere, and communicating
with them. :)
shevegen (Robert A. Heiler)
07:06 PM Feature #14393 (Open): Support sending file descriptors (on local machine) via DRb UNIX
Ruby: `2.4.3p205 (2017-12-14 revision 61247) [x86_64-linux]`
Currently DRb supports UNIX domain sockets, via `drbunix://`
UNIX sockets can transmit file descriptors via `send_io()`/`recv_io()` methods. Unfortunately DRb via `drbuni...
Anonymous
08:52 PM Misc #14395 (Closed): [PATCH] internal.h: add BITFIELD macro
Pretty trivial, will commit soon.
internal.h: add BITFIELD macro
I plan to use this macro to pack other enums in the VM while
preserving portability to non-C99 compilers.
* internal.h: add BITFIELD macro
* method.h: use BITF...
normalperson (Eric Wong)
08:50 PM Revision 0a0b71f3 (git): * 2018-01-25
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62028 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
08:50 PM Revision a41386a2 (git): ruby.c (open_load_file): avoid shadowing variable for errno
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62027 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Eric Wong
05:49 PM Bug #14376: OpenSSL::X509::Store#verify_callback= requires Qtrue, not just truthy
Please close in favor of #14377. graywolf (Gray Wolf)
05:48 PM Feature #14377: Improve documentation for `OpenSSL::X509::Store#verify_callback=` and `OpenSSL::SSL::SSLContext#verify_callback=`
Please close.
I need to learn to read docs. The fact that `Store#verify_callback=` is method (so listed in left pane) while `SSLContext#verify_callback=` is attribute (so NOT listed in left pane) completely got me.
graywolf (Gray Wolf)
04:46 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
k0kubun (Takashi Kokubun) wrote:
> Vladimir, thank you for your opinion on this!
> ...
You are welcome. You are doing a great job.
> > --jit-wait/--jit-threshold are very useful options for testers. They should be used to test JIT ...
vmakarov (Vladimir Makarov)
04:42 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
> I also think that in the future setting JIT features and params through environment variable(s) might improve JIT usage experience too.
Ah, that's a topic that was discussed today too. I'm not going to have them at initial merge, bu...
k0kubun (Takashi Kokubun)
04:40 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
larskanis (Lars Kanis) wrote:
> I like your last proposal most (using `--jit-X` options). It would also allow this in the future:
> ...
I think 16 is too aggressive. It is not only worker threads (many of them will be in a wait state ...
vmakarov (Vladimir Makarov)
04:38 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
Vladimir, thank you for your opinion on this!
> --jit-wait/--jit-threshold are very useful options for testers. They should be used to test JIT on ruby tests (e.g. make check) because without them JIT practically has no time to compil...
k0kubun (Takashi Kokubun)
04:25 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
k0kubun (Takashi Kokubun) wrote:
> > The short form should be there for convenience IMHO
> ...
They look ok to me. I believe people at the developers meeting have the best experience with designing options for C-Ruby. I created origi...
vmakarov (Vladimir Makarov)
04:05 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
I like your last proposal most (using `--jit-X` options). It would also allow this in the future:
```
--jit [<threads>] use MJIT with the number of parallel workers (default: 16)
```
... or even the short form `-jX` .
larskanis (Lars Kanis)
03:44 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
> having "-jX" instead of "-j:t=X" would be very reasonable interface.
I rethought that it's still aggressive to add it while we have --jit-xxx too. Never mind about that part.
k0kubun (Takashi Kokubun)
03:41 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
> Vladimirs command line option -j:t=X sets the number of parallel running compile tasks, which is similar to what -j is typically used for.
Then using "-j" for non-parallel JIT-ing purpose may make it confusing. When JIT becomes stab...
k0kubun (Takashi Kokubun)
03:34 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
Vladimirs command line [option -j:t=X](https://github.com/vnmakarov/ruby/blob/rtl_mjit_branch/ruby.c#L267) sets the number of parallel running compile tasks, which is similar to what `-j` is typically used for. And it is therefore an int... larskanis (Lars Kanis)
02:01 PM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
> The short form should be there for convenience IMHO
TBH I don't have strong preference on having the short versions or not. But I'm expecting that the only option normal user uses would be only "--jit" and others are basically for V...
k0kubun (Takashi Kokubun)
10:43 AM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
Just my opinion: -j only makes sense in the context of a tool/script which can run in parallel (build tool like make, package manager like bundler, etc).
For Ruby, a programming language interpreter, I think -j as --jobs would be meanin...
Eregon (Benoit Daloze)
05:09 AM Feature #14235: Merge MJIT infrastructure with conservative JIT compiler
Before we merge MJIT, we need to consider what CLI options ruby should have.
Current implementation with some modification that I'll add:
~~~
-j, --jit use MJIT with default options
-j:option, --jit:option
...
k0kubun (Takashi Kokubun)
02:48 PM Feature #13581: Syntax sugar for method reference
zverok (Victor Shepelev) wrote:
> map(&Math|>sqrt), each(&|>puts) (too confusable with Elixir-like pipe, probably)
I tend to agree with that.
In fact I was hoping to get the pipe operator introduced in ruby. (Created an issue wit...
dsferreira (Daniel Ferreira)
09:49 AM Feature #13581: Syntax sugar for method reference
Just to push this forward, here are all the syntaxes from this and duplicate #12125.
I am taking `Math.sqrt` and `puts` as examples:
* `map(&Math->sqrt)` (and just `each(&->puts)` probably?) -- Matz is explicitly against it;
* `map(...
zverok (Victor Shepelev)
02:31 PM Revision c5022061 (git): system_spec.rb: add RubySpec for r62025
NEWS: added an entry for `exception: true` option.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62026 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
02:15 PM Feature #14386 (Closed): Add option to let Kernel.#system raise error instead of returning false
Applied in changeset r62025.
For rosenfeld's suggestion, open3 would be a good place to have the functionality.
k0kubun (Takashi Kokubun)
09:00 AM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
I created a patch for exception: true. https://github.com/ruby/ruby/pull/1795 k0kubun (Takashi Kokubun)
07:14 AM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
Agree with adding keyword argument to specify raising an exception (`exception:true` sounds reasonable).
Matz.
matz (Yukihiro Matsumoto)
07:11 AM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
I don't like the keyword name, "assert_status".
I think "exception" is better.
It is consistent with read_nonblock, etc.
akr (Akira Tanaka)
12:04 AM Feature #14386: Add option to let Kernel.#system raise error instead of returning false
> I have nothing against it. I think it would change existing behaviour
though, if I read http://ruby-doc.org/core-2.5.0/Kernel.html#method-i-system
correctly
I don't get what you mean. Do you mean existing program may be passing :a...
k0kubun (Takashi Kokubun)
02:11 PM Revision fb29cffa (git): process.c: add :exception option to Kernel.#system
to raise error when it fails.
[Feature 14386] [GH-1795]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
k0kubun (Takashi Kokubun)
12:57 PM Bug #14391 (Closed): Integer#digitsが遅い
Integer#digitsが遅い
大きなIntegerのdigitsがto_sと比べてかなり遅い(計算量のオーダーが違う)ようです。
~~~ ruby
(9999**9999).to_s.chars.map(&:to_i).reverse # 0.030225秒
(9999**9999).digits # 1.187126秒 (40倍)
(99999**99999).to_s.chars.map(&:to_i).reverse # 1.88821...
tompng (tomoya ishida)
12:30 PM Bug #14389: Reflected XSS
shevegen (Robert A. Heiler) wrote:
> The twitter link above gives me "This account's Tweets are protected.", just
> ...
So what do I have to do?
TheGirdap (Hamit Cibo)
11:58 AM Bug #14389: Reflected XSS
The twitter link above gives me "This account's Tweets are protected.", just
for your information.
shevegen (Robert A. Heiler)
09:11 AM Bug #14389 (Third Party's Issue): Reflected XSS
Hello,
Reflected Xss found ..
https://docs.ruby-lang.org/ja/search/query:import/query:callback/%22%3E%3C/title%3Ealert(XSS%20A%C3%A7%C4%B1%C4%9F%C4%B1)%3C/script%3E%3E%3Cmarquee%3E%3Ch1%3EXSSa%C3%A7%C4%B1%C4%9F%C4%B1%3C/h1%3E%3C/ma...
TheGirdap (Hamit Cibo)
12:18 PM Feature #14390: UnboundMethod#to_proc
@shevegen I am well aware of the process, thanks. In my head, it also includes "ideas are discussed in this bug tracker, then they are added (or not) to next dev.meeting agenda." Do you have a suggestion of the shortcut way of adding it ... zverok (Victor Shepelev)
11:55 AM Feature #14390: UnboundMethod#to_proc
> Ugh, seems it duplicates answer-less #10879.
It can probably be referenced to the other report, and your issue
here closed (or the other one; I think it does not matter which
one).
Some issues are unanswered but this does not n...
shevegen (Robert A. Heiler)
09:22 AM Feature #14390: UnboundMethod#to_proc
Ugh, seems it duplicates answer-less #10879.
Though, I'd be happy to raise the priority of discussion higher, and to provide some real-life examples :)
zverok (Victor Shepelev)
09:18 AM Feature #14390 (Feedback): UnboundMethod#to_proc
I believe that it could be somewhat useful to have UnboundMethod converted to proc (accepting the object to bind to, as a first argument).
Practical(ish) example, paired with [Proc#rcurry](https://bugs.ruby-lang.org/issues/11161) prop...
zverok (Victor Shepelev)
09:11 AM Feature #11161: Proc/Method#rcurry working like curry but in reverse order
Started to write my own ticket, but found this one :)
My explanation was like this:
---
Considering two widespread Ruby patterns:
* Last method arguments are frequently options/settings/clarifications of the call;
* `Method#to...
zverok (Victor Shepelev)
08:40 AM Feature #4830 (Rejected): Provide Default Variables for Array#each and other iterators
Rejected. It would cause too much confusion than convenience.
Matz.
matz (Yukihiro Matsumoto)
08:39 AM Feature #14371: New option "recursive: true" for Hash#transform_keys!
FYI, ActiveSupport implemented these functionalities as separate methods:
* [Hash#deep_transform_keys](http://api.rubyonrails.org/classes/Hash.html#method-i-deep_transform_keys)
* [Hash#deep_transform_keys!](http://api.rubyonrails.or...
sakuro (Sakuro OZAWA)
06:19 AM Feature #14371: New option "recursive: true" for Hash#transform_keys!
I don't think this proposal is a good idea for following reasons:
* `transform_keys` method to modify value part of `Hash`
* `recursive` option to change the behavior this much
* it is much harder to implement `transform_keys(recurs...
matz (Yukihiro Matsumoto)
08:36 AM Bug #4443: odd evaluation order in a multiple assignment
関連すると思われるささださんの昔のメールを見つけました: ruby-dev:31579
```
1) 右辺が重複しないローカル変数の列だったら今まで通り
 (副作用はないので問題ない)
2) そうじゃなければ,色々コストをかけて順番通りに実行
ということにしたいと思います.多分,(1) がほとんどではないかと期待.
ネストした多重代入は (1) にはあてはまりませんが,まぁしょうがない.
```
akr (Akira Tanaka)
08:25 AM Revision 7184e03e (git): mkmf.rb: werror on mswin
* lib/mkmf.rb (MakeMakefile#try_ldflags): enable warning checking
on mswin, link.exe warns -l options but does not fail.
[Bug #13069]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62024 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:22 AM Feature #14240: warn four special variables: $; $, $/ $\
We discussed this issue at today's developper meeting.
We (including matz) agree produce warnings for 5 variables ($; $, $/ $\ $.) when it is written in
ruby code except -e argument.
The warning is produced at compile time.
So th...
akr (Akira Tanaka)
08:14 AM Bug #14388 (Closed): 不正エンコーディング文字列から切り出した正当なエンコーディング文字列が invalid encoding になる
~~~ ruby
data = "\xFFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
p data.encoding #=> #<Encoding:UTF-8>
p data #=> "\xFFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
p data.valid_encoding? #=> false
data2 = da...
tommy (Masahiro Tomita)
08:11 AM Bug #14269: backport r61562, r61563, r61566, r61568, r61569 (fix SEGV touching uninitialized memory)
ruby_2_5 r62023 merged revision(s) 61562,61563,61566,61568,61569. naruse (Yui NARUSE)
08:11 AM Revision 9ceb9e30 (git): merge revision(s) 61562,61563,61566,61568,61569: [Backport #14269]
fix SEGV touching uninitialized memory
This function can be called from boot_defclass().
No assumption can be made about object internals.
(lldb) run
Process 2386 launched: './miniruby' (x86_64)
...
naruse (Yui NARUSE)
08:02 AM Bug #14380 (Assigned): Expected transform_keys! to work just as transform_keys, but it doesn't
mrkn (Kenta Murata)
08:00 AM Bug #14246: Inconsistent C source code indentation
We discussed this issue in today's developer meeting.
- We agreed _not_ to batch update the indents at once. Indents should become consistent over time.
- Matz has no strong opinion on this topic.
- We agreed to move to spaces only...
shyouhei (Shyouhei Urabe)
08:00 AM Feature #12732: An option to pass to `Integer`, `Float`, to return `nil` instead of raise an exception
Just for the record, `Integer(x, rescue: default_value)` might be an idea, if anything other than `nil` (like zero) would be desired. knu (Akinori MUSHA)
07:54 AM Feature #12732: An option to pass to `Integer`, `Float`, to return `nil` instead of raise an exception
Aaron's comment in #note-6 sounds reasonable. Accepted.
Matz.
matz (Yukihiro Matsumoto)
07:16 AM Feature #13969 (Closed): Dir#each_child
Applied in changeset trunk|r62022.
----------
dir.c: Dir#each_child
* dir.c (dir_each_child_m): new instance methods Dir#each_child
and Dir#children. [Feature #13969]
nobu (Nobuyoshi Nakada)
05:59 AM Feature #13969: Dir#each_child
Agreed.
Matz.
matz (Yukihiro Matsumoto)
07:15 AM Revision 6a3a7e91 (git): dir.c: Dir#each_child
* dir.c (dir_each_child_m): new instance methods Dir#each_child
and Dir#children. [Feature #13969]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
06:32 AM Revision f7210deb (git): NEWS: [Feature #14223] [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62021 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
06:28 AM Feature #14313: Support creating KeyError with receiver and key from Ruby
I agree with the original proposal. We are not going to enhance `raise` behavior (yet).
Matz.
matz (Yukihiro Matsumoto)
06:25 AM Feature #14223 (Closed): Refinements で定義した #to_proc が &hoge 時に呼ばれないのを緩和する提案
Applied in changeset trunk|r62020.
----------
vm_args.c: to_proc refinements
* vm_args.c (vm_to_proc): enable #to_proc by refinements at Proc
passing as a block. patched by osyo (manga osyo).
[Feature #14223]
nobu (Nobuyoshi Nakada)
06:00 AM Feature #14223: Refinements で定義した #to_proc が &hoge 時に呼ばれないのを緩和する提案
良さそうに思えます。取り込んでみましょう。
Matz.
matz (Yukihiro Matsumoto)
06:25 AM Revision a6e5073c (git): vm_args.c: to_proc refinements
* vm_args.c (vm_to_proc): enable #to_proc by refinements at Proc
passing as a block. patched by osyo (manga osyo).
[Feature #14223]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
06:17 AM Feature #14382: Make public access of a private constant call const_missing
matz (Yukihiro Matsumoto) wrote:
> The idea seems OK to me. Can you experiment?
With the attached patch, both test-all and test-spec pass.
The only time I can see this causing an issue is in a class/module that overrides `const_mi...
jeremyevans0 (Jeremy Evans)
05:35 AM Feature #14382: Make public access of a private constant call const_missing
The idea seems OK to me. Can you experiment?
Matz.
matz (Yukihiro Matsumoto)
03:33 AM Feature #14383: Making prime_division in prime.rb Ruby 3 ready.
Well, I did say "serious" math, didn't I.
```
2.5.0 :097 > 2**256
=> 115792089237316195423570985008687907853269984665640564039457584007913129639936
2.5.0 :099 > n = 2**256 + 1; tm{ pp n.factors }
[[1238926361552897, ...
jzakiya (Jabari Zakiya)
12:34 AM Feature #14362: use BigDecimal instead of Float by default
Rational and BigDecimal do not cover irrational numbers.
```ruby
require 'bigdecimal'
p (BigDecimal("2.0")**BigDecimal("0.5"))**BigDecimal("2.0")
#=> 0.19999999932878736e1
```
You'd need a mathematical solver, not a mere numeri...
nobu (Nobuyoshi Nakada)
12:29 AM Bug #14387 (Closed): Ruby 2.5 を Alpine Linux で実行すると比較的浅めで SystemStackError 例外になる
CircleCI で Alpine Linux を使って Ruby 2.5.0 で Rubocop を実行した時に遭遇した例外です(Ruby 2.4.3 では発生しませんでした)。
Ruby のバージョンによって、再帰が止められるまでの回数に大きな違いがあるのはなぜでしょうか?
これは、意図された挙動なのか、Ruby の変更によるものでは無く Alpine Linux 固有の問題なのか、教えていただく事は可能でしょうか?
Alpine Linux の Tr...
koshigoe (Masataka SUZUKI)
12:12 AM Revision c786db20 (git): Fix a typo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62019 b2dd03c8-39d4-4d8f-98ff-823fe69b080e yui-knk (Kaneko Yuichiro)
12:03 AM Bug #14264 (Closed): RDoc comment of warn does not mention uplevel:
Applied in changeset trunk|r62018.
----------
Add documentation for the Kernel#warn :uplevel keyword
[ruby-core:84574] [Bug #14264]
Author: Jeremy Evans <code@jeremyevans.net>
Anonymous
12:03 AM Revision 49a23c27 (git): Add documentation for the Kernel#warn :uplevel keyword
[ruby-core:84574] [Bug #14264]
Author: Jeremy Evans <code@jeremyevans.net>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62018 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
znz (Kazuhiro NISHIYAMA)
 

Also available in: Atom