[#66126] Creation/Conversion methods/functions table for Ruby types — SASADA Koichi <ko1@...>
Hi,
5 messages
2014/11/07
[#66248] [ruby-trunk - Feature #10423] [PATCH] opt_str_lit*: avoid literal string allocations — normalperson@...
Issue #10423 has been updated by Eric Wong.
3 messages
2014/11/13
[#66595] [ruby-trunk - Bug #10557] [Open] Block not given when the argument is a string — bartosz@...
Issue #10557 has been reported by Bartosz Kopinski.
3 messages
2014/11/30
[ruby-core:66274] [ruby-trunk - misc #10500] [Rejected] Improve Pathname.glob documentation
From:
nobu@...
Date:
2014-11-14 02:00:38 UTC
List:
ruby-core #66274
Issue #10500 has been updated by Nobuyoshi Nakada.
Status changed from Open to Rejected
----------------------------------------
misc #10500: Improve Pathname.glob documentation
https://bugs.ruby-lang.org/issues/10500#change-49948
* Author: Thibault Jouan
* Status: Rejected
* Priority: Normal
* Assignee: Akira Tanaka
* Category: ext
* Target version: current: 2.2.0
----------------------------------------
I was confused by two things about current `Pathname.glob`
documentation:
Pathname.glob("config/" "*.rb")
#=> [#<Pathname:config/environment.rb>, #<Pathname:config/routes.rb>, ..]
* `"config/" "*.rb"` is not valid syntax
* glob pattern should be given only as first argument, second argument
are flags documented with `Dir.glob`
I'm suggesting an update example inspired by those found in
`Dir.glob`, making use of `File.join` (good practice from my point of
view, encourage not specifying the directory separator):
config_rb_files = File.join('config', '*.rb')
Pathname.glob(config_rb_files)
#=> [#<Pathname:config/environment.rb>, #<Pathname:config/routes.rb>, ...]
I also replaced tabs with spaces on the results line (is there a
policy about this?)
And changed the ellipsis from `..` to `...`, like the others.
I set an assignee, based on what I saw on
https://bugs.ruby-lang.org/projects/ruby/wiki/MaintainersStdlib, hope
I'm correct.
---Files--------------------------------
0001-Improve-Pathname.glob-documentation-example.patch (1.04 KB)
--
https://bugs.ruby-lang.org/