On Mon, Aug 16, 2010 at 1:14 PM, Daniel Sheppard <daniels / pronto.com.au> wrote:
> ruby -v
> ruby 1.8.7 (2010-06-23 patchlevel 299) [i686-linux]
> Same bug exists in the jruby implementation as well.

iianm, it fails for ruby ver below 1.9.2.  it is fixed ruby1.9.2

botp@jedi2:~
$ for i in `rvm list strings`; do rvm $i; ruby -v -ryaml test.rb; done
ruby 1.8.6 (2010-02-05 patchlevel 399) [i686-linux]
"--- \ndefault: |-\n  \r\n    Monkey \r\n  X\n"
/disk2_2/home/botp/.rvm/rubies/ruby-1.8.6-p399/lib/ruby/1.8/yaml.rb:133:in
`load': syntax error on line 4, col 2: `  X' (ArgumentError)
	from /disk2_2/home/botp/.rvm/rubies/ruby-1.8.6-p399/lib/ruby/1.8/yaml.rb:133:in
`load'
	from test.rb:4
ruby 1.8.7 (2009-06-12 patchlevel 174) [i686-linux]
"--- \ndefault: |-\n  \r\n    Monkey \r\n  X\n"
/disk2_2/home/botp/.rvm/rubies/ruby-1.8.7-p174/lib/ruby/1.8/yaml.rb:133:in
`load': syntax error on line 4, col 2: `  X' (ArgumentError)
	from /disk2_2/home/botp/.rvm/rubies/ruby-1.8.7-p174/lib/ruby/1.8/yaml.rb:133:in
`load'
	from test.rb:4
ruby 1.8.7 (2010-06-23 patchlevel 299) [i686-linux]
"--- \ndefault: |-\n  \r\n    Monkey \r\n  X\n"
/disk2_2/home/botp/.rvm/rubies/ruby-1.8.7-p299/lib/ruby/1.8/yaml.rb:133:in
`load': syntax error on line 4, col 2: `  X' (ArgumentError)
	from /disk2_2/home/botp/.rvm/rubies/ruby-1.8.7-p299/lib/ruby/1.8/yaml.rb:133:in
`load'
	from test.rb:4
ruby 1.9.1p378 (2010-01-10 revision 26273) [i686-linux]
"--- \ndefault: |-\n  \r\n    Monkey \r\n  X\n"
/disk2_2/home/botp/.rvm/rubies/ruby-1.9.1-p378/lib/ruby/1.9.1/yaml.rb:133:in
`load': syntax error on line 4, col 2: `  X' (ArgumentError)
	from /disk2_2/home/botp/.rvm/rubies/ruby-1.9.1-p378/lib/ruby/1.9.1/yaml.rb:133:in
`load'
	from test.rb:4:in `<main>'

ruby 1.9.2dev (2010-05-31 revision 28117) [i686-linux]
"--- \ndefault: \"\\r\\n  Monkey \\r\\n\\\n  X\"\n"
ruby 1.9.2dev (2010-07-02 revision 28524) [i686-linux]
"--- \ndefault: \"\\r\\n  Monkey \\r\\n\\\n  X\"\n"
ruby 1.9.2dev (2010-07-11 revision 28618) [i686-linux]
"--- \ndefault: \"\\r\\n  Monkey \\r\\n\\\n  X\"\n"

botp@jedi2:~

best regards -botp