undefined method 'add_ruby_type' for YAML:Module
------------------------------------------------
Key: JRUBY-3266
URL: http://jira.codehaus.org/browse/JRUBY-3266
Project: JRuby
Issue Type: Bug
Components: Core Classes/Modules
Affects Versions: JRuby 1.1.6
Environment: Mac OSX 10.5.6, Java 1.5.0_16, ruby 1.8.6 (2008-03-03
patchlevel 114) [universal-darwin9.0]
Reporter: Yue Ni
Attachments: yaml_extension.rb
The following code snippet will cause an error in JRuby 1.1.6 but without any
error in Ruby 1.8.6
{code}
YAML.add_ruby_type(/^class/) do |type, val|
subtype, subclass = YAML.read_type_class(type, Class)
val.split(/::/).inject(Object) { |p, n| p.const_get(n)}
end
{code}
JRuby will complain that "undefined method `add_ruby_type' for YAML:Module
(NoMethodError)". But add_ruby_type method should be implemented in yaml in
standard library.
--
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