From: naruse@... Date: 2014-02-22T09:17:14+00:00 Subject: [ruby-core:61008] [ruby-trunk - Bug #9354] timeout() custom exception class cannot require argument Issue #9354 has been updated by Yui NARUSE. Backport changed from 1.9.3: DONTNEED, 2.0.0: DONTNEED, 2.1: REQUIRED to 1.9.3: DONTNEED, 2.0.0: DONTNEED, 2.1: DONE ruby_2_1 r44841 merged revision(s) 44517,44518,44519,44523. ---------------------------------------- Bug #9354: timeout() custom exception class cannot require argument https://bugs.ruby-lang.org/issues/9354#change-45410 * Author: Aman Gupta * Status: Closed * Priority: Normal * Assignee: Yui NARUSE * Category: lib * Target version: next minor * ruby -v: trunk * Backport: 1.9.3: DONTNEED, 2.0.0: DONTNEED, 2.1: DONE ---------------------------------------- The following code works on 2.0.0, but raises on 2.1.0: require 'timeout' class MyError < StandardError def initialize(msg) super end end timeout(1, MyError){} $ ruby -v ruby 2.1.0p0-github (2013-12-31 revision 44488) [x86_64-darwin13.0] $ ruby /tmp/test.rb /tmp/test.rb:4:in `initialize': wrong number of arguments (0 for 1) (ArgumentError) The patch attached resolves this issue. ---Files-------------------------------- timeout_klass_arg.patch (795 Bytes) -- http://bugs.ruby-lang.org/