Project

General

Profile

Activity

From 10/17/2015 to 10/23/2015

10/23/2015

11:54 PM Revision 880f7151 (git): common.mk: remove extra slash
* common.mk (incs): remove extra slash before
vm_call_iseq_optimized.inc. as nmake vpath syntax includes a
separator, don't append it.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52262 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
11:37 PM Revision a8b56b9e (git): common.mk: vm_call_iseq_optimized.inc
* common.mk (incs): generate vm_call_iseq_optimized.inc too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
10:41 PM Revision 11ec42e3 (git): parse.y: canonical name
* parse.y (parser_magic_comment): intern canonical name.
InstructionSequence.compile_options are case-sensitive while
pragma names are case-insensitive.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52260 b2dd03c8-39d4-4d8f-98ff...
nobu (Nobuyoshi Nakada)
10:29 PM Bug #11616 (Closed): Forwardable fails to adjust backtrace when Forwardable is not reachable from the target class
Applied in changeset r52259.
----------
forwardable.rb: full qualify names
* lib/forwardable.rb (def_instance_delegator, def_single_delegator):
match backtraces against ::Forwardable in case the target class
is a subclass of BasicO...
nobu (Nobuyoshi Nakada)
10:29 PM Bug #11616: Forwardable fails to adjust backtrace when Forwardable is not reachable from the target class
I think that backtrace cleanup should be removed as well as delegate.rb, [Bug #11461]. nobu (Nobuyoshi Nakada)
09:17 PM Bug #11616 (Closed): Forwardable fails to adjust backtrace when Forwardable is not reachable from the target class
as follows:
```
$ cat t.rb
require "forwardable"
class Foo < BasicObject
extend ::Forwardable
def_delegator :bar, :baz
end
Foo.new.baz
$ ruby t.rb
/Users/guest/.rbenv/versions/trunk/lib/ruby/2.3.0/forwardable.rb:1...
wanabe (_ wanabe)
10:29 PM Revision 4e1ee809 (git): forwardable.rb: full qualify names
* lib/forwardable.rb (def_instance_delegator, def_single_delegator):
match backtraces against ::Forwardable in case the target class
is a subclass of BasicObject and does not include Kernel.
[ruby-core:71176] [Bug #11616]
git-svn-...
nobu (Nobuyoshi Nakada)
07:13 PM Revision 92d5da52 (git): * iseq.c (make_compile_option_value): include frozen_string_literal*
in a made option value.
* vm_opts.h: forgot to add OPT_FROZEN_STRING_LITERAL_DEBUG
at last commit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52258 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
ko1 (Koichi Sasada)
07:02 PM Revision 54716fe7 (git): * ruby.c: introduce --enable-frozen-string-literal-debug option.
If this option is enabled, the modify error will be:
can't modify frozen String (RuntimeError) =>
can't modify frozen String, created at test.rb:3 (RuntimeError)
* iseq.h: add compile option frozen_string_literal_debug.
* compi...
ko1 (Koichi Sasada)
05:53 PM Revision 31f21aed (git): * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
05:53 PM Revision 593cf11a (git): * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
05:53 PM Revision f9697c56 (git): * vm_insnhelper.c: introduce new call handler for simple ISeqs.
vm_call_iseq_setup_normal_0start() is simple, however it has
some loops/conditions depends on ISeq::param.size and
ISeq::local_size (in vm_push_frame(), inlined into this function).
There are many simple methods which has a few pa...
ko1 (Koichi Sasada)
05:00 PM Revision 1e060032 (git): * vm_core.h: define vm_call_handler.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52253 b2dd03c8-39d4-4d8f-98ff-823fe69b080e ko1 (Koichi Sasada)
04:57 PM Revision 9e1b06e1 (git): * vm_core.h, vm_insnhelper.h: move definition of VMDEBUG
from vm_insnhelper.h to vm_core.h.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52252 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
ko1 (Koichi Sasada)
04:53 PM Revision 1b5dce5a (git): * NEWS: [DOC] In the new safe call syntax, arguments are evaluated
only if a call is made.
* doc/syntax/calling_methods.rdoc: Fix a typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52251 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Akinori MUSHA
03:41 PM Bug #11615 (Closed): Forwardable fails to adjust backtrace when Exception is defined in the target class
Applied in changeset r52249.
----------
* lib/forwardable (def_instance_delegator, def_single_delegator):
rescue ::Exception instead of Exception in case Exception is
defined under the target class.
[ruby-core:71175] [Ruby trunk -...
shugo (Shugo Maeda)
03:36 PM Bug #11615 (Closed): Forwardable fails to adjust backtrace when Exception is defined in the target class
Forwardable fails to adjust backtrace when Exception is defined in the target class as follows:
```
$ cat t.rb
require "forwardable"
class Foo
extend Forwardable
def_delegator :bar, :baz
class Exception
end
end
...
shugo (Shugo Maeda)
03:41 PM Revision 4daa1cf7 (git): * 2015-10-24
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52250 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
03:41 PM Revision 8c8e17d4 (git): * lib/forwardable (def_instance_delegator, def_single_delegator):
rescue ::Exception instead of Exception in case Exception is
defined under the target class.
[ruby-core:71175] [Ruby trunk - Bug #11615]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52249 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
shugo (Shugo Maeda)
02:27 PM Revision f8a83d85 (git): error.c: use fake string
* error.c (name_err_mesg_to_str): use fake string as rb_str_format
does not require T_STRING to be cannonical VALUE.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52248 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
12:10 PM Revision 5bf61f45 (git): error.c: separate class names
* error.c (name_err_mesg_to_str): separate class names from the
receiver description.
* vm_eval.c (make_no_method_exception, raise_method_missing): add
format specifiers for class names.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/t...
nobu (Nobuyoshi Nakada)
10:12 AM Bug #11596 (Closed): Getting [BUG] rb_vm_get_cref: unreachable
sorry i missed #1 comment written by wanabe-san.
if it can be reproduced yet, please reopen this ticket.
ko1 (Koichi Sasada)
09:36 AM Bug #7758: Ruby on Windows crashes when active codepage is codepage 65001 and outputting unicode character
Has this patch been applied?
Because I'm getting pretty much the same crash on 32bit 2.1.7p400 running on Win7 64x and I can reproduce.
arcandros (Vassilis Rizopoulos)
09:10 AM Revision e3b07883 (git): * .gitignore: ignored environmantal wrapper files.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e hsbt (Hiroshi SHIBATA)
08:55 AM Revision 00d8b1a8 (git): * lib/irb.rb: Ignored assignment of STDOUT.sync = true
when irb.rb loaded. It's affected to IDE such as Jetbrain.
[fix GH-864] Patch by @os97673
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52245 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hsbt (Hiroshi SHIBATA)
07:35 AM Bug #11513 (Closed): IPAddr should reject invalid formats
Applied in changeset r52244.
----------
* lib/ipaddr.rb, test/test_ipaddr.rb: Reject invalid address contained
EOL string. Patch by @kachick [fix GH-942][Bug #11513]
hsbt (Hiroshi SHIBATA)
07:35 AM Revision 2cd1f852 (git): * lib/ipaddr.rb, test/test_ipaddr.rb: Reject invalid address contained
EOL string. Patch by @kachick [fix GH-942][Bug #11513]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52244 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hsbt (Hiroshi SHIBATA)
07:07 AM Revision 2697fb49 (git): ChangeLog: adjust indent
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52243 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nobu (Nobuyoshi Nakada)
07:03 AM Revision 5fdee2f8 (git): * file.c: fix indent style. [fix GH-977]
* test/ruby/test_string.rb: indent. [fix GH-975]
[ci skip] These patches are contributed from @yui-knk
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52242 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hsbt (Hiroshi SHIBATA)
06:46 AM Revision 26cd2da7 (git): * string.c: Added method signature to include hash. It's inconsistency
with `gsub` method signature.
[ci skip][fix GH-1023] Patch by @danielevans
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52241 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hsbt (Hiroshi SHIBATA)
06:29 AM Revision e0ea5e90 (git): * lib/net/imap.rb: remove an empty comment line and -*-.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52240 b2dd03c8-39d4-4d8f-98ff-823fe69b080e shugo (Shugo Maeda)
06:23 AM Revision 3eabc555 (git): * lib/net/ftp.rb (gettextfile, getbinaryfile): use the safe
navigation operator.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52239 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
shugo (Shugo Maeda)
04:51 AM Revision 1d3c0763 (git): test_call.rb: add tests
* test_call.rb (test_safe_call): Add test cases for safe
navigation operator assignment. [Fix GH-1064]
Validate:
* can assign an attribute which is `nil`
* can "or assign" an attribute which is `nil`
git-svn-id: svn+ssh://ci.ru...
nobu (Nobuyoshi Nakada)
03:58 AM Feature #11537: Introduce "Safe navigation operator"
Thanks for the thoughtful replies guys! That definitely helps clarify the `.?` operator
Matthew Kerwin wrote:
> On 23/10/2015 2:46 AM, <merch-redmine@jeremyevans.net> wrote:
> ...
treznick (Tom Reznick)
02:58 AM Revision ae8f8fdd (git): compile.c: optimize method chain
* compile.c (iseq_peephole_optimize): optimize lengthy safe
navigation method chain. [Feature #11537]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52237 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
02:09 AM Revision 4f9ded5c (git): * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
02:09 AM Revision d07ce082 (git): * lib/matrix/eigenvalue_decomposition.rb (tridiagonalize): fix
indentation to avoid a warning when the command line option -w of
ruby is specified.
* lib/matrix/eigenvalue_decomposition.rb (hessenberg_to_real_schur):
change the name of a block parameter to avoid a warning when the
command lin...
shugo (Shugo Maeda)
01:49 AM Revision 0b7d4737 (git): safe navigation attrset
* compile.c (iseq_compile_each): support safe navigation of simple
attribute assignment. [Feature #11537]
* parse.y (mlhs_node, lhs, attrset_gen): ditto. keep mid
non-attrset as the sign of safe navigation.
git-svn-id: svn+ssh://c...
nobu (Nobuyoshi Nakada)
01:47 AM Revision 7e730322 (git): compile.c: just insert
* compile.c (compile_massign_lhs): just insert topn insn instead
of popping and adding. [Feature #11537]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52233 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)

10/22/2015

11:48 PM Feature #9025: Clarify the error message when calling a method with the wrong number of arguments
On 23 October 2015 at 07:51, <duerst@it.aoyama.ac.jp> wrote:

> Issue #9025 has been updated by Martin Dürst.
>
> Matthew Kerwin wrote:
> > duerst (Martin Dürst) wrote:
>
> > > Ruby is all about making it easier for the programme...
phluid61 (Matthew Kerwin)
09:51 PM Feature #9025: Clarify the error message when calling a method with the wrong number of arguments
Matthew Kerwin wrote:
> duerst (Martin Dürst) wrote:
> ...
It might have been clearer for me to write "Even the smallest reduction in the amount of debugging is worth it when it can be achieved by tweaking the error message."
Anyw...
duerst (Martin Dürst)
09:11 AM Feature #9025: Clarify the error message when calling a method with the wrong number of arguments
"(expected: 1, provided: 0)" is excellent. This is a big usability issue. Python's message is similar, and includes the function name:
`TypeError: fun() takes exactly 1 argument (0 given)`
> I agree that someone not familiar with m...
robb (Robb Shecter)
11:42 PM Revision 418fa65d (git): NEWS: add a space
* NEWS: fix wording, "Active Support" has a space in between the
words, not ActiveSupport.
https://github.com/ruby/ruby/commit/a356fe1#commitcomment-13936198
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52232 b2dd03c8-39d4-4d8f...
nobu (Nobuyoshi Nakada)
10:25 PM Revision d4fd2fb0 (git): test/io/wait/test_io_wait.rb (test_wait_eof): test return value
I wrote some code which relies on this nowadays, but Ruby <=2.2
and earlier behaved differently...
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52231 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Eric Wong
09:28 PM Feature #11537: Introduce "Safe navigation operator"
On 23/10/2015 2:46 AM, <merch-redmine@jeremyevans.net> wrote:
>
> Issue #11537 has been updated by Jeremy Evans.
>
>
> Tom Reznick wrote:
> > Hi,
> >
> > I think we may have found some unexpected behavior with the `.?`
operator...
phluid61 (Matthew Kerwin)
04:45 PM Feature #11537: Introduce "Safe navigation operator"
Tom Reznick wrote:
> Hi,
> ...
I think it's completely expected that `nil.?kind_of?(NilClass)` returns `nil` and not `true`. The whole point of `.?` is to return `nil` without calling the method if the receiver is `nil`. I'm not sure...
jeremyevans0 (Jeremy Evans)
04:34 PM Feature #11537: Introduce "Safe navigation operator"
I know this is already decided and the commit is out there, but since you are adding new syntax and a new feature to the language, I suggest you reconsider https://bugs.ruby-lang.org/issues/9076
With that change, instead of adding spe...
asterite (Ary Borenszweig)
04:29 PM Feature #11537: Introduce "Safe navigation operator"
Hi,
I think we may have found some unexpected behavior with the `.?` operator.
If I call the following:
s = Struct.new(:x)
o = s.new()
o.x #=> nil
o.x.nil? #=> true
o.x.?nil? #=> nil
o.x.kind_of?(Nil...
treznick (Tom Reznick)
06:30 AM Feature #11537 (Closed): Introduce "Safe navigation operator"
Applied in changeset r52214.
----------
Safe navigation operator
* compile.c (iseq_peephole_optimize): peephole optimization for
branchnil jumps.
* compile.c (iseq_compile_each): generate save navigation operator
code.
* insns.def ...
nobu (Nobuyoshi Nakada)
08:54 PM Feature #11614 (Closed): [RFC] use id_table for constant tables
ref: [ruby-core:71142] [ruby-core:71151]
I'm not sure if using rb_class_name in object.c is enough to prevent
breaking all existing code. Until this is sufficiently reviewed,
I have no plans to commit this patch at the moment.
v...
normalperson (Eric Wong)
08:36 PM Revision d737d576 (git): NEWS: fix typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52230 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Eric Wong
05:55 PM Feature #11181: Add a line directive to Ruby
The pull request is now at https://github.com/ruby/ruby/pull/911 gam3 (Allen Morris)
04:55 PM Bug #11613 (Closed): test_aspawn_too_long_path creates too many processes
Applied in changeset r52229.
----------
Add rlimit_nproc to avoid to create many process [Bug #11613]
naruse (Yui NARUSE)
04:52 PM Bug #11613 (Closed): test_aspawn_too_long_path creates too many processes
At least on FreeBSD, spawn("echo|echo|echo|echo|echo|echo|echo| ...20000 times") success and create 20000 zombie processes.
To prevent this you can add rlimit_nproc: 1 because it tests sh itself, don't test spawned echos.
```diff
di...
naruse (Yui NARUSE)
04:54 PM Revision 7b90b137 (git): Add rlimit_nproc to avoid to create many process [Bug #11613]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52229 b2dd03c8-39d4-4d8f-98ff-823fe69b080e naruse (Yui NARUSE)
04:54 PM Bug #11369 (Closed): Check length of selected NPN protocol
Applied in changeset r52227.
----------
* ext/openssl/ossl_ssl.c (ssl_npn_select_cb): explicitly raise error
in ext/openssl instead of OpenSSL itself because LibreSSL
silently truncate the selected protocol name by casting the lengt...
naruse (Yui NARUSE)
04:54 PM Revision b5f2b5e1 (git): ALPN also uses the same logic [Bug #11369]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52228 b2dd03c8-39d4-4d8f-98ff-823fe69b080e naruse (Yui NARUSE)
04:54 PM Revision d7d779b5 (git): * ext/openssl/ossl_ssl.c (ssl_npn_select_cb): explicitly raise error
in ext/openssl instead of OpenSSL itself because LibreSSL
silently truncate the selected protocol name by casting the length
from int to unsigned char. [Bug #11369]
Patch by Jeremy Evans <merch-redmine@jeremyevans.net>
git-svn-id:...
naruse (Yui NARUSE)
03:51 PM Revision e4d925bf (git): * lib/un.rb (help): change the name of a block parameter to avoid
a warning when the command line option -w of ruby is specified.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52226 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
shugo (Shugo Maeda)
03:22 PM Revision bcc07ef4 (git): fix backslash [ci skip]
* string.c (rb_str_tr): [DOC] Escape backslash in String#tr
documentation. [Fix GH-1063]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
03:19 PM Revision 77a952d1 (git): adjust spaces [ci skip]
* array.c (rb_ary_collect): [DOC] Fix space of code example of
Array#map. [Fix GH-1062]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52224 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
03:00 PM Revision 439c3e23 (git): * 2015-10-23
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52223 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
03:00 PM Revision b471c9d3 (git): limit the number of FDs in a process for stress test
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52222 b2dd03c8-39d4-4d8f-98ff-823fe69b080e naruse (Yui NARUSE)
02:56 PM Revision 29a1905c (git): common.mk: showflags only once
* common.mk (showflags): do not show flags from recursive make.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
02:31 PM Bug #11604 (Rejected): Ruby's interpreting hash symbol keys as parts of Ruby syntax
Yes, it's your bug. nobu (Nobuyoshi Nakada)
01:19 PM Bug #11604: Ruby's interpreting hash symbol keys as parts of Ruby syntax
That is true but IMHO it should still be considered as a bug. maciej.mensfeld (Maciej Mensfeld)
11:43 AM Bug #11604 (Feedback): Ruby's interpreting hash symbol keys as parts of Ruby syntax
Maciej Mensfeld wrote:
> Cannot initialize hashes with some Ruby reserved keywords like: while, until, if, unless, do. Can with other like class, end, elsif, super. Don't really get why
These syntax errors are not caused by key names...
shugo (Shugo Maeda)
02:02 PM Revision be8a9db5 (git): colorize
* tool/generic_erb.rb: use VT100 sequence if tput does not work.
* tool/ifchange: ditto and add --color option.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52220 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
01:53 PM Bug #11611 (Closed): uncommon.mk:853: recipe for target '.revision.time' failed
Applied in changeset r52219.
----------
ifchange: ignore error
* tool/ifchange: do not exit by -e even if tput failed.
[ruby-core:71143] [Bug #11611]
nobu (Nobuyoshi Nakada)
10:05 AM Bug #11611 (Open): uncommon.mk:853: recipe for target '.revision.time' failed
Reopened, because I still get an error, as follows:
~~~
$ make up; make install-nodoc
Updating '.':
At revision 52218.
make[1]: Entering directory '/cygdrive/c/Data/ruby-public'
uncommon.mk:853: recipe for target '.revision.time'...
duerst (Martin Dürst)
08:56 AM Bug #11611 (Closed): uncommon.mk:853: recipe for target '.revision.time' failed
Applied in changeset r52215.
----------
generic_erb.rb: ignore error
* tool/generic_erb.rb: ignore error that tput is not found.
[ruby-core:71143] [Bug #11611]
nobu (Nobuyoshi Nakada)
06:45 AM Bug #11611 (Closed): uncommon.mk:853: recipe for target '.revision.time' failed
When trying to compile Ruby trunk with
`make up; make install-nodoc`
I get the following errors:
~~~
$ make up; make install-nodoc
Updating '.':
At revision 52214.
make[1]: Entering directory '/cygdrive/c/Data/ruby-public'
unco...
duerst (Martin Dürst)
01:53 PM Revision 35957b76 (git): ifchange: ignore error
* tool/ifchange: do not exit by -e even if tput failed.
[ruby-core:71143] [Bug #11611]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52219 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
12:12 PM Feature #10181: New method File.openat()
Technorama Ltd. wrote:
> The proposed Dir api must provide a way to open both files and directories in order to be useful.
> ...
I prefer the following style:
d1 = Dir.open("d1") #=> a Dir
d2 = Dir.openat(d1, "subdir") #=> ...
shugo (Shugo Maeda)
10:53 AM Bug #10031: Net::IMAP idle can still block a thread forever.
I've added a new argument `timeout` for Net::IMAP#idle to solve this problem.
For example, the following code checks the connection for each 60 seconds.
loop do
imap.idle(60) do |res|
...
end
end
shugo (Shugo Maeda)
09:32 AM Bug #10031 (Closed): Net::IMAP idle can still block a thread forever.
Applied in changeset r52216.
----------
* lib/net/imap (idle): add a new argument timeout for keep-alive.
[ruby-core:63693] [Bug #10031]
shugo (Shugo Maeda)
09:58 AM Feature #11498 (Closed): Kernel#loop: return the "result" value of StopIteration
Applied in changeset r52218.
----------
Kernel#loop returns the result value of a finished iterator
* vm_eval.c (rb_f_loop): When a loop is stopped by a StopIteration
exception, return what the enumerator has returned instead of
ni...
knu (Akinori MUSHA)
09:58 AM Revision f4c48717 (git): Kernel#loop returns the result value of a finished iterator
* vm_eval.c (rb_f_loop): When a loop is stopped by a StopIteration
exception, return what the enumerator has returned instead of
nil. [ruby-core:71133] [Feature #11498]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52218 b2dd03c...
Akinori MUSHA
09:32 AM Revision 53d6e605 (git): * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52217 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
09:32 AM Revision 68fc350a (git): * lib/net/imap (idle): add a new argument timeout for keep-alive.
[ruby-core:63693] [Bug #10031]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52216 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
shugo (Shugo Maeda)
09:12 AM Misc #11295: Request for comments about error messages
See also "Clarify the error message when calling a method with the wrong number of arguments", https://bugs.ruby-lang.org/issues/9025 robb (Robb Shecter)
08:48 AM Misc #11295: Request for comments about error messages
Koichi Sasada wrote:
>
> ...
Again, thanks for posting this.
I believe that some small changes can make Ruby error messages more helpful. E.g., I've just begun working on a Pull Request to change the rb_eArgError messages from e.g...
robb (Robb Shecter)
08:42 AM Misc #11295: Request for comments about error messages
Thanks for starting this discussion!
> And some requests.
> ...
+1 for this. It's how Python displays backtraces. That's a good precedent to follow. I find that senior devs (like myself) and brand new developers (like my students) of...
robb (Robb Shecter)
08:56 AM Revision 30b839a0 (git): generic_erb.rb: ignore error
* tool/generic_erb.rb: ignore error that tput is not found.
[ruby-core:71143] [Bug #11611]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52215 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:54 AM Feature #11612 (Closed): The default mode of Net::FTP should be passive
The default mode of Net::FTP is active for historical reasons, but it should be changed to passive
because active data connections might be blocked by a local firewall.
Passive data connections might also be blocked by a firewall, but ...
shugo (Shugo Maeda)
06:30 AM Revision a356fe1c (git): Safe navigation operator
* compile.c (iseq_peephole_optimize): peephole optimization for
branchnil jumps.
* compile.c (iseq_compile_each): generate save navigation operator
code.
* insns.def (branchnil): new opcode to pop the tos and branch if
it is nil.
*...
nobu (Nobuyoshi Nakada)
06:25 AM Revision 5a599dde (git): generic_erb.rb: highlight
* tool/generic_erb.rb: highlight result messages too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52213 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
04:16 AM Bug #11609 (Closed): Dir.glob brace expansion possible edge case
Applied in changeset r52212.
----------
dir.c: glob brace expansion [Fix GH-1061]
* dir.c (ruby_brace_expand): glob brace expansion edge case fix.
When there are closing braces '}' before a open brace '{' it
must be ignored and con...
nobu (Nobuyoshi Nakada)
12:56 AM Bug #11609 (Closed): Dir.glob brace expansion possible edge case
I found an edge case of Dir.glob that don't work as i was expecting, and as my shell works.
It may happens on every version. I discovered it after spelunking through: ruby_brace_expand function on dir.c (https://github.com/ruby/ruby...
guilhermereiscampos (Guilherme Reis Campos)
04:16 AM Revision ff3288fe (git): dir.c: glob brace expansion [Fix GH-1061]
* dir.c (ruby_brace_expand): glob brace expansion edge case fix.
When there are closing braces '}' before a open brace '{' it
must be ignored and considered as literal.
[ruby-core:71138] [Bug #11609]
git-svn-id: svn+ssh://ci.ruby-...
nobu (Nobuyoshi Nakada)
04:14 AM Bug #11610 (Closed): Segfault when assigning to ARGV
Applied in changeset r52211.
----------
io.c: check ARGV element type
* io.c (argf_next_argv): check ARGV element type, and try
conversion if necessary. [ruby-core:71140] [Bug #11610]
nobu (Nobuyoshi Nakada)
01:17 AM Bug #11610 (Closed): Segfault when assigning to ARGV
This causes a segfault:
~~~
seq 3 | ruby -ne 'ARGV[$.]=$_'
~~~
These similar ones don't:
~~~
seq 3 | ruby -e 'ARGV[0] = "abc"'
seq 3 | ruby -ne 'BEGIN{a=[]}; a[$.]=$_'
~~~
Here is the output:
~~~
-e:1: [BUG] Segmenta...
josh.cheek (Josh Cheek)
04:13 AM Revision 66e41cbe (git): io.c: check ARGV element type
* io.c (argf_next_argv): check ARGV element type, and try
conversion if necessary. [ruby-core:71140] [Bug #11610]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52211 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
02:21 AM Revision 23419d85 (git): * 2015-10-22
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52210 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
02:21 AM Revision 19110fe1 (git): * test/net/ftp/test_ftp.rb: add tests for getbinaryfile and
gettextfile.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52209 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
shugo (Shugo Maeda)

10/21/2015

11:33 PM Feature #11537: Introduce "Safe navigation operator"
Marc-Andre Lafortune wrote:
> Just to be clear, this will check only for `nil`, right?
I think so, and my implementation too.
nobu (Nobuyoshi Nakada)
07:29 PM Feature #11537: Introduce "Safe navigation operator"
Great!
Just to be clear, this will check only for `nil`, right?
nil.?foo # => nil
false.?foo # => NoMethodError
marcandre (Marc-Andre Lafortune)
10:20 AM Feature #11537: Introduce "Safe navigation operator"
Great news! Thanks! Is this going to be released on next minor or on Ruby 3 only? rosenfeld (Rodrigo Rosenfeld Rosas)
08:05 AM Feature #11537: Introduce "Safe navigation operator"
Oh, I made mistake. We will introduce `.?` (typo fixed already). matz (Yukihiro Matsumoto)
07:45 AM Feature #11537: Introduce "Safe navigation operator"
In several languages (Groovy Swift etc.), use `?.` but we cannot use it in Ruby, because `foo?` is a valid method name.
Thus `.?` is a reasonable alternative for Ruby, I think.
Accepted.
Matz.
matz (Yukihiro Matsumoto)
08:38 PM Feature #11415: autoload with a Proc
matz@ruby-lang.org wrote:
> > I hate autoload. autoload is one of things I regret. I'm not positive about enhancing something I hate.
> -- matz in https://speakerdeck.com/skade/the-dark-side-of-matz-1

Would you like autoload if Rub...
normalperson (Eric Wong)
12:53 PM Feature #11415: autoload with a Proc
> I hate autoload. autoload is one of things I regret. I'm not positive about enhancing something I hate.
-- matz in https://speakerdeck.com/skade/the-dark-side-of-matz-1
How about using `const_missing`?
Matz.
matz (Yukihiro Matsumoto)
12:48 PM Feature #11498: Kernel#loop: return the "result" value of StopIteration
I like the idea. If anything bad happens by the patch, I'd love to accept this.
Matz.
matz (Yukihiro Matsumoto)
09:34 AM Feature #8976 (Closed): file-scope freeze_string directive
Applied in changeset r52208.
----------
parse.y: magic comment w/o indicators
* parse.y (parser_magic_comment): allow a sole magic comment without
indicators, neither other non-space comments. [Feature #8976]
nobu (Nobuyoshi Nakada)
02:57 AM Feature #8976 (Assigned): file-scope freeze_string directive
Benoit Daloze wrote:
> Yusuke Endoh wrote:
> ...
+1
This issue should be discussed at the developers meeting today, and Matz should desicde whether `-*-` should be required.
shugo (Shugo Maeda)
09:34 AM Revision a76fdea9 (git): parse.y: magic comment w/o indicators
* parse.y (parser_magic_comment): allow a sole magic comment without
indicators, neither other non-space comments. [Feature #8976]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52208 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
08:06 AM Feature #11034 (Closed): Nil Conditional
We will introduce `.?` #11537 which address this proposal.
Matz.
matz (Yukihiro Matsumoto)
07:16 AM Revision 5fe69193 (git): Makefile.in: tty at reconfig
* aclocal.m4 (_COLORIZE_RESULT_PREPARE): force tty for reconfig.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52207 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
12:36 AM Revision 21494036 (git): * 2015-10-21
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52206 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
12:35 AM Revision de2d4510 (git): extconf.rb: strict_warnflags
* ext/date/extconf.rb: add strict warning flags same as ruby
itself for C99 option.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52205 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)

10/20/2015

10:28 PM Feature #11607: [PATCH] fiddle: release GVL for ffi_call
v2 fixes a warning I did not notice before, interdiff:
~~~
--- a/ext/fiddle/closure.c
+++ b/ext/fiddle/closure.c
@@ -64,7 +64,7 @@ struct callback_args {
void *ctx;
};

-static void
+static void *
with_gvl_callback(void...
normalperson (Eric Wong)
05:14 PM Bug #11598: Ruby crash when I run calabash-android
Hello, clint.
Could you provide full error messages in your command prompt?
nagachika (Tomoyuki Chikanaga)
02:40 PM Bug #11608 (Closed): test -t without fd
Applied in changeset r52204.
----------
test -t
* aclocal.m4, tool/ifchange: make the fd explict.
[ruby-dev:49311] [Bug #11608]
nobu (Nobuyoshi Nakada)
01:30 PM Bug #11608 (Closed): test -t without fd
r52202 で fd 指定なしの test -t を使っていますが、
http://pubs.opengroup.org/onlinepubs/9699919799/utilities/test.html
の RATIONALE で
> The -t file_descriptor primary is shown with a mandatory argument because the grammar is ambiguous if it can be ...
znz (Kazuhiro NISHIYAMA)
02:40 PM Revision 2bb1e93d (git): test -t
* aclocal.m4, tool/ifchange: make the fd explict.
[ruby-dev:49311] [Bug #11608]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52204 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
12:42 PM Bug #11602: Compile error on CentOS: Segmentation fault after "linking miniruby"
Some additional information. Version 2.2.3 didn't compiled with the same error message. But Ruby from the stable snapshot (https://ftp.ruby-lang.org/pub/ruby/stable-snapshot.tar.gz) compiled successfully:
stable-snapshot# make
...
P...
Ruben_r (Ruben Ambarcumyanc)
10:40 AM Bug #11602: Compile error on CentOS: Segmentation fault after "linking miniruby"
ruby-2.1.7 # gdb miniruby core.17835
GNU gdb (GDB) CentOS (7.0.1-45.el5.centos)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: yo...
Ruben_r (Ruben Ambarcumyanc)
10:27 AM Bug #11602: Compile error on CentOS: Segmentation fault after "linking miniruby"
(gdb) backtrace
#0 0x00002b739984f0bb in reserve_stack (limit=0x7fff44a7b0c0 <Address 0x7fff44a7b0c0 out of bounds>, size=10481408) at thread_pthread.c:685
#1 0x00002b739984f134 in ruby_init_stack (addr=0x7fff45479258) at thread_pthr...
Ruben_r (Ruben Ambarcumyanc)
10:07 AM Bug #11603: Count trace_running for internal event
assigning ko1 at here too, because he has self-assigned at GitHub PR sorah (Sorah Fukumori)
07:15 AM Revision 96003bc9 (git): missing.h: fix condition
* include/ruby/missing.h (bytesequence4_or_float): define by
configured result.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52203 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
07:15 AM Revision e4879592 (git): highlight configure
* aclocal.m4 (COLORIZE_RESULT): highlight result messages.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52202 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
03:23 AM Bug #11606: Prime.prime? should throw error on invalid inputs
Totally agree. I hope you'll find my fix acceptable.
Thanks for creating the issue
marcandre (Marc-Andre Lafortune)
03:20 AM Bug #11606 (Closed): Prime.prime? should throw error on invalid inputs
Applied in changeset r52201.
----------
* lib/prime.rb: Add basic argument checking to Prime.prime?
[Bug #11606]
marcandre (Marc-Andre Lafortune)
03:19 AM Revision 48773664 (git): * lib/prime.rb: Add basic argument checking to Prime.prime?
[Bug #11606]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52201 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Marc-Andre Lafortune
03:18 AM Feature #10354 (Closed): Optimize Integer#prime?
Applied in changeset r52200.
----------
* lib/prime.rb: Optimize Integer#prime?
Patch by Nick Slocum [Bug #10354]
marcandre (Marc-Andre Lafortune)
03:18 AM Revision 8744d516 (git): * lib/prime.rb: Optimize Integer#prime?
Patch by Nick Slocum [Bug #10354]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52200 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Marc-Andre Lafortune

10/19/2015

11:24 PM Revision 49efa668 (git): * configure.in: pthread_getattr_np is broken on AIX.
More specifically, the stack address and size returned are
not correct.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Rei Odaira
09:46 PM Feature #11607 (Closed): [PATCH] fiddle: release GVL for ffi_call
Some external functions I wish to call may take a long time
and unnecessarily block other threads. This may lead to performance
regressions for fast functions as releasing/acquiring the GVL is not
cheap, but can improve performance f...
normalperson (Eric Wong)
09:46 PM Bug #11606 (Closed): Prime.prime? should throw error on invalid inputs
irb(main):003:0> Prime.prime?(1,3)
=> false
irb(main):004:0> Prime.prime?(1.3)
=> false
irb(main):005:0> Prime.prime?(20.3)
=> true
Prime.prime? converts floating point numbers to integer to determine if they are prime. A prime ...
chaitanyav (NagaChaitanya Vellanki)
08:56 PM Revision cfa2f954 (git): ext/fiddle/closure.c (callback): static function
The `callback' function is not used outside of closure.c and
should not be able to cause namespace conflicts in compilers
without visibility pragmas.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52198 b2dd03c8-39d4-4d8f-98ff-823fe6...
Eric Wong
06:49 PM Feature #11599: Dump entries of hash in ObjectSpace
Yosi Attias wrote:
> Nobuyoshi Nakada wrote:
> ...
Hi,
I have added to reflect the new logic:
* If the key/value are special consts - I write the "to_s" value of them (:a => "a", 1 => "1")
* If the key/value are not special consts -...
yosiat (Yosi Attias)
06:28 PM Feature #11599: Dump entries of hash in ObjectSpace
Nobuyoshi Nakada wrote:
> That distinction makes no sense.
> ...
Oh.. I understand what you are saying, I will fix that!
Just to make sure I understand your position, you say this distinction is not needed, and in case of this hash:
...
yosiat (Yosi Attias)
06:52 AM Feature #11599: Dump entries of hash in ObjectSpace
That distinction makes no sense.
Non-special-const objects (including `String`) are always shown in pointer reference form.
That `"0x007f8f3c8baf88"` is the content of a string but not the pointer, then it never appears with your patch.
nobu (Nobuyoshi Nakada)
05:28 AM Feature #11599: Dump entries of hash in ObjectSpace
Nobuyoshi Nakada wrote:
> Yosi Attias wrote:
> ...
Yes, but how can you distinguish between string value which is address or address to other ruby object:
`h = {a: "0x007f8f3c8baf88"}` to `h = {a: {b: 1}}`
yosiat (Yosi Attias)
01:50 AM Feature #11599: Dump entries of hash in ObjectSpace
Yosi Attias wrote:
> and to make sure there are no confusion some one did some like this:
> ...
I can't get your point here.
`{"key":":a","value":"0x007f8f3c8baf88"}` seems clear enough to me.
nobu (Nobuyoshi Nakada)
05:17 PM Feature #11605: Ruby should raise on def(a='a', b) [optional param that can't be used]
Oh, thanks. I had no idea on how to try this. I've tried a(, 'required'). Actually, I was reading a method like a(req1, opt='opt', req2) and thought it would be impossible to use the default value, but now I understand how optional argum... rosenfeld (Rodrigo Rosenfeld Rosas)
05:12 PM Feature #11605 (Rejected): Ruby should raise on def(a='a', b) [optional param that can't be used]
Why did not you try actually?
~~~
irb(main):001:0> def a(opt='opt',required)
irb(main):002:1> p [opt, required]
irb(main):003:1> end
=> :a
irb(main):004:0> a('required')
["opt", "required"]
=> ["opt", "required"]
~~~
usa (Usaku NAKAMURA)
04:49 PM Feature #11605 (Rejected): Ruby should raise on def(a='a', b) [optional param that can't be used]
Why doesn't Ruby complain when defining a method like this?
~~~
def a(opt='opt', required)
end
~~~
I believe it's impossible to call method 'a' passing only required, while sticking to the default value for 'opt', right? So, why...
rosenfeld (Rodrigo Rosenfeld Rosas)
04:29 PM Revision 603cdc27 (git): check INFINITY and NAN without C99 option
* configure.in: check INFINITY and NAN without an option for C99
so that rb_infinity and rb_nan are respectively available
regardless that option if they may be used.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52197 b2dd03c8-...
nobu (Nobuyoshi Nakada)
04:28 PM Revision 9949407f (git): suppress a warning
* ext/socket/raddrinfo.c (rsock_fd_family): suppress a
sign-compare warning.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52196 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
03:55 PM Revision 61d51d9d (git): * 2015-10-20
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52195 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
03:55 PM Revision dba4adb5 (git): fix typos [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52194 b2dd03c8-39d4-4d8f-98ff-823fe69b080e znz (Kazuhiro NISHIYAMA)
03:54 PM Revision dca182f2 (git): fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52193 b2dd03c8-39d4-4d8f-98ff-823fe69b080e znz (Kazuhiro NISHIYAMA)
03:35 PM Bug #11604 (Rejected): Ruby's interpreting hash symbol keys as parts of Ruby syntax
Cannot initialize hashes with some Ruby reserved keywords like: while, until, if, unless, do. Can with other like class, end, elsif, super. Don't really get why
~~~
{ while: 1 } # Will fail
# error.rb:3: syntax error, unexpected ':'...
maciej.mensfeld (Maciej Mensfeld)
02:47 PM Bug #11603 (Closed): Count trace_running for internal event
https://github.com/ruby/ruby/pull/1059
I want to fix a crash: https://gist.github.com/k0kubun/86fd9fbff32423bd4974
I noticed that clean_hooks can be executed inside exec_hooks_body.
The hooks of list->hooks can be xfreed during e...
k0kubun (Takashi Kokubun)
02:15 PM Bug #11602: Compile error on CentOS: Segmentation fault after "linking miniruby"
Can't you show gdb backtrace? nobu (Nobuyoshi Nakada)
02:09 PM Bug #11602 (Rejected): Compile error on CentOS: Segmentation fault after "linking miniruby"
Hi,
I can't to compile Ruby 2.1.7 on the one of our servers:
configure:
ruby-2.1.7 # ./configure
...
checking for nroff... /usr/bin/nroff
.ext/include/x86_64-linux/ruby/config.h updated
ruby library version = 2.1.0
configure: c...
Ruben_r (Ruben Ambarcumyanc)
12:10 PM Bug #11601 (Closed): error: implicit declaration of function ‘ENC_GET’
Applied in changeset r52192.
----------
file.c: fix typos
* file.c (rb_file_expand_path_internal): fix typos.
[ruby-core:71111] [Bug #11601]
nobu (Nobuyoshi Nakada)
08:50 AM Bug #11601 (Closed): error: implicit declaration of function ‘ENC_GET’
When trying to compile Ruby trunk with
make up; make install-nodoc
I get the following errors:
compiling file.c
file.c: In function ‘rb_file_expand_path_internal’:
file.c:3561:2: error: implicit declaration of function ‘ENC_GE...
duerst (Martin Dürst)
12:10 PM Revision a3ac9d0b (git): file.c: fix typos
* file.c (rb_file_expand_path_internal): fix typos.
[ruby-core:71111] [Bug #11601]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52192 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
06:25 AM Revision c92322b5 (git): objspace_dump.c: special const
* ext/objspace/objspace_dump.c: support special constant objects.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52191 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
01:34 AM Bug #11600 (Closed): indeterministic failures on socket operations when running out of file descriptors
Applied in changeset r52190.
----------
init.c: glibc bug
* ext/socket/init.c (rsock_raise_socket_error): get rid of a glibc
bug. [ruby-core:71100] [Bug #11600]
nobu (Nobuyoshi Nakada)
01:34 AM Bug #11600: indeterministic failures on socket operations when running out of file descriptors
Accurately, it is not a bug but an intentional crash.
Citing from [`libdispatch-442.1.4/src/source.c`](https://opensource.apple.com/tarballs/libdispatch/libdispatch-442.1.4.tar.gz):
~~~c
int err = errno;
switch (err) {
cas...
nobu (Nobuyoshi Nakada)
12:48 AM Bug #11600: indeterministic failures on socket operations when running out of file descriptors
Erkki Eilonen wrote:
> Happens on OSX (10.10.5) as well (on 2.2.3 and earlier, presumably on latest 2_2 as well)
It's a bug of a system library.
We can do nothing for it.
nobu (Nobuyoshi Nakada)
01:33 AM Revision 7594a993 (git): init.c: glibc bug
* ext/socket/init.c (rsock_raise_socket_error): get rid of a glibc
bug. [ruby-core:71100] [Bug #11600]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52190 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)

10/18/2015

05:18 PM Feature #11599: Dump entries of hash in ObjectSpace
Nobuyoshi Nakada wrote:
> Are `is_{key,value}_address` necessary?
Yes, If the key/value are composite objects (not special consts, like string/hash/class) then the values of "key"/"value" should be address which is *pointer to other ...
yosiat (Yosi Attias)
01:24 PM Feature #11599: Dump entries of hash in ObjectSpace
Are `is_{key,value}_address` necessary?
nobu (Nobuyoshi Nakada)
04:30 PM Revision 3ef4dfdc (git): * 2015-10-19
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52189 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
04:29 PM Revision a01dfd47 (git): * file.c (rb_file_identical_p): not necessary to compare the paths after
comparing the file indexes on Windows. designate by kosaki.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52188 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
U.Nakamura
03:02 PM Bug #11600: indeterministic failures on socket operations when running out of file descriptors
Motohiro KOSAKI wrote:
> In my system, getaddrinfo() return -11(EAI_SYSTEM) and errno=0. That seems glibc's bug.
> ...
Happens on OSX (10.10.5) as well (on 2.2.3 and earlier, presumably on latest 2_2 as well)
~~~
➜ ruby test.rb
10...
erkkie (Erkki Eilonen)
01:07 PM Bug #11600: indeterministic failures on socket operations when running out of file descriptors
In my system, getaddrinfo() return -11(EAI_SYSTEM) and errno=0. That seems glibc's bug.
I guess this is related to https://sourceware.org/bugzilla/show_bug.cgi?id=15339.
kosaki (Motohiro KOSAKI)
12:36 PM Bug #11600: indeterministic failures on socket operations when running out of file descriptors
Managed to get the testcase slightly simpler with a guaranteed ruby crash. tarmo_t (Tarmo Tänav)
10:24 AM Bug #11600 (Closed): indeterministic failures on socket operations when running out of file descriptors
We've been getting indeterministic failures on socket operations when running out of file descriptors, instead of the correct `Errno::EMFILE` being raised we've seen various failure modes, on both linux and osx:
1. This is what we're ...
erkkie (Erkki Eilonen)
02:59 PM Revision 0bb6bf24 (git): * ruby/test_require.rb (loading_fifo): checking by defined? is meaningless about
notimplemented method. such methods are defined, but not respond_to?. this
fixes test failures introduced at r52172.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52187 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
U.Nakamura
12:17 PM Revision 89db37cf (git): * lib/open-uri.rb: Specify frozen_string_literal: true.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52186 b2dd03c8-39d4-4d8f-98ff-823fe69b080e akr (Akira Tanaka)
10:21 AM Revision 4eba615a (git): disable warnings unless optimized
* include/ruby/ruby.h (rb_data_object_{wrap,get}): move
declarations inside ifdef too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52185 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
05:53 AM Revision 6094ac4c (git): disable warnings unless optimized
* include/ruby/ruby.h (rb_data_object_{wrap,get,make}): warn only
if optimized, as __builtin_choose_expr() does not work fine
unless optimized.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52184 b2dd03c8-39d4-4d8f-98ff-823fe69b...
nobu (Nobuyoshi Nakada)
05:51 AM Revision 503752b1 (git): random.c: comment [ci skip]
* random.c (fill_random_bytes_urandom): fix comment typos.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52183 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
05:46 AM Revision 0751bc3f (git): Revert r52180
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52182 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
05:43 AM Revision 6c060b2b (git): * random.c (fill_random_bytes_urandom): add a comment why using
O_NONBLOCK and O_NOCTTY.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52181 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
kosaki (Motohiro KOSAKI)
05:42 AM Revision 47f0a8f9 (git): * random.c (fill_random_bytes_syscall): don't use GRND_NONBLOCK.
It is meaningless. If SYS_getrandom(GRND_NONBLOCK) return
EAGAIN, we eventually call fill_random_bytes_urandom() and
it block such as SYS_getrandom() without GRND_NONBLOCK.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52180 b2d...
kosaki (Motohiro KOSAKI)
05:42 AM Revision a4c6ad1d (git): * random.c (fill_random_bytes_syscall): use ATOMIC_SET() for
updating try_syscall.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52179 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
kosaki (Motohiro KOSAKI)
05:41 AM Revision 0bdf13a1 (git): * include/ruby/backward/util.h: Good-by Borland-C.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52178 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
05:40 AM Revision 727ae6f8 (git): * common.mk: add a comment how to use "make test-all"
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52177 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
05:40 AM Revision 75356fc8 (git): * common.mk: add comments how to use "make benchmark"
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
04:22 AM Revision 1d1ee07f (git): ruby.c: disable nonblock only if nonblocking mode
* ruby.c (open_load_file): disable O_NONBLOCK only when opened in
non-blocking mode, to get rid of LoadError on Windows.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52175 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
03:58 AM Revision 3d61b259 (git): * lib/securerandom.rb: Specify frozen_string_literal: true.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e akr (Akira Tanaka)
03:07 AM Revision 61685c76 (git): test_require.rb: no guarantees to load FIFO
* test/ruby/test_require.rb (loading_fifo): loading from FIFO is
not guaranteed, it just should not block the whole process.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
02:40 AM Revision 7cb20b8f (git): test_require.rb: test conditions
* test/ruby/test_require.rb (loading_fifo): check by if FIFO is
available or not, instead of platform names.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52172 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
02:23 AM Revision 348d7b09 (git): * dln.c: remove defined(__WATCOMC__).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
02:17 AM Revision 3a49d353 (git): * lib/mkmf.rb: Good-by Borland-C (cont).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
02:11 AM Revision 5b9f32c2 (git): * append newline at EOF.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
02:10 AM Revision 3a48e126 (git): * numeric.c: Good-by Borland-C.
* include/ruby/backward/rubyio.h: ditto.
* include/ruby/backward/st.h: ditto.
* include/ruby/backward/util.h: ditto.
* include/ruby/backward/rubysig.h: ditto.
* include/ruby/backward/classext.h: ditto.
* dln.c: ditto.
* gc.c: ditto.
* wi...
kosaki (Motohiro KOSAKI)
02:08 AM Revision e91baf56 (git): * dln.c: simplify #ifdef. _WIN32 and __CYGWIN__ are exclusive.
see include/ruby/defines.h
* gc.c: ditto.
* ext/sdbm/_sdbm.c: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
kosaki (Motohiro KOSAKI)
01:44 AM Revision a923a6f0 (git): * ruby.c (open_load_file): add a comment.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52166 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
01:43 AM Revision 395dd786 (git): fix compile error
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52165 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
01:30 AM Revision 3d7a5354 (git): file.c: fix compile error
* file.c (rb_file_s_rename): remove unmatched endif not removed at
r52161.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52164 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
01:19 AM Revision a857b11d (git): * file.c (rb_file_identical_p): simplify ifdefs
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52163 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
01:18 AM Revision 64a08a54 (git): * append newline at EOF.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52162 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
01:18 AM Revision 4ad2057f (git): * ChangeLog: Good-bye OS/2.
* common.mk: ditto.
* configure.in: ditto.
* dln_find.c: ditto.
* ext/Setup.emx: ditto.
* ext/extmk.rb: ditto.
* ext/socket/extconf.rb: ditto.
* ext/zlib/extconf.rb: ditto.
* file.c: ditto.
* include/ruby/defines.h: ditto.
* io.c: ditto....
kosaki (Motohiro KOSAKI)
01:17 AM Revision 6803c4e2 (git): * include/ruby/defines.h (DOSISH): add comments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
12:40 AM Revision a0a77c5b (git): re-commit r52152
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52159 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
12:33 AM Revision 21704f22 (git): * file.c (ruby_is_fd_loadable): this should be fail if st_mode is
not regular file nor FIFO.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
kosaki (Motohiro KOSAKI)
12:21 AM Revision 698f6648 (git): * ruby.c (open_load_file): use rb_thread_wait_fd() instead of reopen.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52157 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)
12:13 AM Revision ff132bc0 (git): Revert r52154
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e kosaki (Motohiro KOSAKI)

10/17/2015

11:59 PM Revision acc94eb9 (git): ruby.c: unnecessary variable
* ruby.c (open_load_file): remove unnecessary nested local
variable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
11:43 PM Bug #11559: ビジーループの thread と YAML.parse を組み合わせたときの実行時間が 2.2.3 で遅くなっている
せっかくなので、 did_you_meanが入っても 2.2.0より早くなるよう、r52152で高速化パッチを入れました。Rubyではrequireの速度が超重要であることが経験的に分かっているので、IO.close処理にそれ用の最適化を入れてみました。
$ make benchmark OPTS="-r 10 -p bm_require_t -e ruby-trunk -e ruby-2.2.2"
build-ruby: 0.171...
kosaki (Motohiro KOSAKI)
09:30 PM Bug #11559: ビジーループの thread と YAML.parse を組み合わせたときの実行時間が 2.2.3 で遅くなっている
調査してみたところ、今回のケースではGVLの所有権変更はすべてIO.closeを契機に行われており、
要するにopenの回数が変わっているのですが、それはなにかというと did_you_mean.
gem_prelude.rbから require 'did_you_mean' を削除してみたところ、以下のように性能劣化が
なくなりました。
ruby 2.0.0p598 (2014-11-13) [x86_64-linux] 1.527653928
ruby...
kosaki (Motohiro KOSAKI)
11:41 PM Revision d6379666 (git): file.c: set errno
* file.c (ruby_is_fd_loadable): set proper errno.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
11:38 PM Revision d5cb997f (git): ruby.c: suppress warnings
* ruby.c (loadopen_func): suppress a warning, unused function.
* ruby.c (open_load_file): suppress warnings, results of close(2).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52153 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
11:31 PM Revision 50024f9d (git): * io.c (fptr_finalize): don't release gvl if fptr is not writable.
writable fd may block on close(2) when it's on NFS. But readonly
fd doesn't. [Bug #11559]
result: make benchmark OPTS="-p bm_require_t -e ruby-trunk -e ruby-2.2.2"
build-ruby: 0.171
ruby 2.3.0dev(r52151): 0.659
...
kosaki (Motohiro KOSAKI)
09:38 PM Bug #11060: load(fifo) blocks whole process
修正メモ
r50887 はakrパッチにあったS_ISFIFO()のチェックが入っていないため、FIFOがemptyじゃなくなるまで待つが、待った後エラーになってしまいロードできていませんでした。
FIFOから正常にロードできるテストが存在しないのがよくないので、当該テスト足しました。
また、rb_file_load_ok()を修正するのは論理的におかしくて、rb_file_load_ok()でロードできるかどうか一度チェックしてから一旦クローズ、
再度 l...
kosaki (Motohiro KOSAKI)
09:09 PM Bug #11060 (Closed): load(fifo) blocks whole process
Applied in changeset r52151.
----------
* ruby.c (open_load_file): reset O_NONBLOCK after open.
Even if S_ISREG() is true, the file may be file on FUSE filesystem
or something. We can't assume O_NONBLOCK is safe.
Moreover, we shou...
kosaki (Motohiro KOSAKI)
09:09 PM Revision bc8687ac (git): * ruby.c (open_load_file): reset O_NONBLOCK after open.
Even if S_ISREG() is true, the file may be file on FUSE filesystem
or something. We can't assume O_NONBLOCK is safe.
Moreover, we should wait if the path is point to FIFO. That's
FIFO semantics. GVL should be transparent from ruby ...
kosaki (Motohiro KOSAKI)
04:40 PM Revision 9ec8d4ef (git): * 2015-10-18
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e svn[bot]
04:39 PM Revision 058ba6ce (git): * ChangeLog: remove duplicated entry of r52147. [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52149 b2dd03c8-39d4-4d8f-98ff-823fe69b080e nagachika (Tomoyuki Chikanaga)
12:06 PM Feature #11599 (Assigned): Dump entries of hash in ObjectSpace
Hi,
*This is my first c code contribution :)*
I am helping developing heap-analyzer (github.com/tenderlove/heap-analyzer), and currently the dumps lacks of "type metadata" information, like:
* Hash entries - the keys and value
...
yosiat (Yosi Attias)
05:01 AM Revision eb4dc179 (git): test_const.rb: suppress warnings
* test/ruby/test_const.rb (test_redefinition_memory_leak):
suppress warnings instead of redirecting to null device.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
04:55 AM Revision 78baa98e (git): string.c: rb_str_cat_conv_enc_opts
* file.c (rb_file_expand_path_internal): concatenate converted
string to the result instead of making converted string and
append it.
* string.c (rb_str_cat_conv_enc_opts): from rb_str_conv_enc_opts,
separate function to concatenat...
nobu (Nobuyoshi Nakada)
04:31 AM Revision c72ddc44 (git): file.c: prefer encoding index as possible
* file.c (rb_str_encode_ospath): prefer encoding index as possible
until rb_encoding is needed.
* file.c (rb_file_expand_path_internal): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
04:19 AM Revision c1a6fdc8 (git): ruby.c: unify nested code
* ruby.c (load_file): unify each preparations and clean-ups by
merging load_file_internal and load_file_internal2, and remove
nested rb_protect and rb_ensure.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52145 b2dd03c8-39d4-4d8...
nobu (Nobuyoshi Nakada)
04:07 AM Revision f63ad355 (git): vm_insnhelper.c: suppress a warning
* vm_insnhelper.c (vm_yield_with_cfunc): cast to suppress a
warning by VC.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
04:03 AM Revision 4bc884c4 (git): ruby.c: conflicting O_NONBLOCK
* ruby.c (load_file_internal): do not use O_NONBLOCK when
conflicting with O_ACCMODE.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
nobu (Nobuyoshi Nakada)
12:30 AM Bug #11596: Getting [BUG] rb_vm_get_cref: unreachable
Reproduced.
```
$ ruby -v -I lib:test test/cases/scoping/default_scoping_test.rb -n test_default_scope_select_ignored_by_grouped_aggregations
ruby 2.3.0dev (2015-10-15 trunk 52128) [x86_64-linux]
Using sqlite3
Run options: -n test...
wanabe (_ wanabe)
 

Also available in: Atom