printf "%s" - strange behavior
------------------------------

                 Key: JRUBY-902
                 URL: http://jira.codehaus.org/browse/JRUBY-902
             Project: JRuby
          Issue Type: Bug
    Affects Versions: JRuby 0.9.9
         Environment: Intel Mac OSX 10.4.9
            Reporter: Alan Hensel
            Assignee: Thomas E Enebo
         Attachments: TestPrintf.rb

This is hard to describe, but easy to demonstrate:

#!/usr/bin/ruby
game = '41181 jpa:awh'
opponent = game.scan("jpa")[0]
puts opponent
printf "%s\n", opponent

Ruby output:
jpa
jpa

JRuby output:
jpa
411

Attached TestUnit test uses sprintf.

-- 
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

Reply via email to