From: "devans (Daniel Evans)" Date: 2012-04-29T15:40:49+09:00 Subject: [ruby-core:44753] [ruby-trunk - Bug #6378][Open] irb incorrectly considers line incomplete when parenthesis are excluded Issue #6378 has been reported by devans (Daniel Evans). ---------------------------------------- Bug #6378: irb incorrectly considers line incomplete when parenthesis are excluded https://bugs.ruby-lang.org/issues/6378 Author: devans (Daniel Evans) Status: Open Priority: Normal Assignee: Category: Target version: ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-darwin11.2.0] Steps to reproduce: start irb attempt to execute the following line: [1,2,3].reduce :+ Expected: a result of `=> 6` should be printed and a new line should be available Actual: The result is not printed and the shell indicates more lines are expected irb(main):001:0> [1,2,3].reduce :+ irb(main):002:0* Workaround: add parenthesis to the method call: [1,2,3].reduce(:+) Notes: The line is executed, as evidenced by changing the symbol to represent a message to which FixNum does not respond, such as :_ after which the error message will be printed immediately. This is also reproducible in ruby 1.8.7 (2010-06-23 patchlevel 299) [x86_64-linux] irb versions tested: irb 0.9.6(09/06/30) irb 0.9.5(05/04/13) -- http://bugs.ruby-lang.org/