Project

General

Profile

Actions

Bug #5542

closed

Ruby 1.9.3-p0 changed arity on default initialization method

Added by jballanc (Joshua Ballanco) over 12 years ago. Updated over 12 years ago.

Status:
Rejected
Target version:
ruby -v:
ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-darwin11.2.0]
Backport:
[ruby-core:40647]

Description

The following code worked under 1.9.2-p290 but breaks with an Argument Error (1 for 0) under 1.9.3-p0:

class Foo; end
Foo.new(nil)

Furthermore, the reported arity for Object's initialize method has changed:

ruby-1.9.2-p290 :001 > Object.instance_method(:initialize).arity
 => -1 

ruby-1.9.3-p0 :001 > Object.instance_method(:initialize).arity
 => 0 

Files

noname (500 Bytes) noname Anonymous, 11/04/2011 01:23 AM

Related issues 1 (0 open1 closed)

Related to Ruby master - Feature #2451: BasicObject.initialize with variable number of argumentClosedmatz (Yukihiro Matsumoto)12/07/2009Actions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0