[#74190] [Ruby trunk Feature#12134] Comparison between `true` and `false` — duerst@...
SXNzdWUgIzEyMTM0IGhhcyBiZWVuIHVwZGF0ZWQgYnkgTWFydGluIETDvHJzdC4KCgpUc3V5b3No
3 messages
2016/03/07
[#74269] Type systems for Ruby — Rob Blanco <ml@...>
Dear ruby-core,
5 messages
2016/03/10
[#74395] [Ruby trunk Feature#12142] Hash tables with open addressing — shyouhei@...
Issue #12142 has been updated by Shyouhei Urabe.
3 messages
2016/03/17
[ruby-core:74097] [Ruby trunk Bug#12136] OpenStruct.new(format: :bar).send :format # => too few arguments
From:
mail@...
Date:
2016-03-02 12:53:28 UTC
List:
ruby-core #74097
Issue #12136 has been updated by Niko Dittmann. It's this commit: https://github.com/ruby/ruby/blob/7fa21558051e5412dcb790f528e392476edd4389/lib/ostruct.rb By defining the getters and setters lazily the Kernel instance methods shine through and #method_missing doesn't kick in. ---------------------------------------- Bug #12136: OpenStruct.new(format: :bar).send :format # => too few arguments https://bugs.ruby-lang.org/issues/12136#change-57243 * Author: Niko Dittmann * Status: Open * Priority: Normal * Assignee: * ruby -v: ruby 2.3.0p0 (2015-12-25 revision 53290) [x86_64-linux] * Backport: 2.1: UNKNOWN, 2.2: UNKNOWN, 2.3: UNKNOWN ---------------------------------------- #send(:format) to an OpenStruct with a field named :format raises an ArgumentError in Ruby 2.3.0: ~~~ OpenStruct.new(format: :bar).send :format ArgumentError: too few arguments ~~~ It works as expected in ruby 2.2.1p85 (2015-02-26 revision 49769) [x86_64-linux] and with any other method name I tried: ~~~ OpenStruct.new(f: :bar).send :f => :bar ~~~ String or Symbol in the OpenStruct definition and as argument of #send make no difference. -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:[email protected]?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>