From: "drbrain (Eric Hodel)" Date: 2012-11-17T10:20:10+09:00 Subject: [ruby-core:49471] [ruby-trunk - Feature #7363] Remove the global Pathname() method Issue #7363 has been updated by drbrain (Eric Hodel). =begin (({Pathname()})) matches (({Integer()})), (({Array()})), (({URI()})), etc. I would prefer to keep (({Pathname()})) in the tradition of these other methods. =end ---------------------------------------- Feature #7363: Remove the global Pathname() method https://bugs.ruby-lang.org/issues/7363#change-33002 Author: aef (Alexander E. Fischer) Status: Open Priority: Normal Assignee: Category: lib Target version: About a year ago I sumbitted an not yet accepted patch for Ruby on GitHub which deprecates the global Pathname() method and adds the .[] operator to the Pathname class. The patch got ignored, supposedly because I didn't post it here. https://github.com/ruby/ruby/pull/61 I think poisoning the global namespace with methods named after classes should be considered bad style. Instead, all related methods should lie below the Class' namespace. I hope you share that opinion. As some User once suggested that probably only collection type classes (e.g. Set) should have a .[] operator, I'm no longer proposing to add .[] instead to Pathname. If you like the idea, please let me know. I will modify the patch then. -- http://bugs.ruby-lang.org/