block inside string interpolation raises error in 1.9 mode ----------------------------------------------------------
Key: JRUBY-5360 URL: http://jira.codehaus.org/browse/JRUBY-5360 Project: JRuby Issue Type: Bug Components: Ruby 1.9 Affects Versions: JRuby 1.6RC1 Environment: Mac OS X 10.6.6 Reporter: Raimonds Simanovskis Assignee: Thomas E Enebo This example script {code:ruby} puts <<-EOS test block inside string interpolation #{ (1..10).map do |i| i end.join(',') } EOS {code} works in JRuby 1.6RC1 1.8 mode but if I run it with --1.9 then I get syntax error: {code} : block_inside_string.rb:4: syntax error, unexpected kDO_BLOCK (SyntaxError) (1..10).map do |i| ^ {code} If I run it with ruby 1.9.2-p136 then it works as well so I assume this is JRuby 1.9 mode parser bug. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email