ruby-changes:15366
From: nobu <ko1@a...>
Date: Thu, 8 Apr 2010 11:32:36 +0900 (JST)
Subject: [ruby-changes:15366] Ruby:r27256 (trunk): * lib/yaml.rb (YAML::EngineManager#yamler): set the result after
nobu 2010-04-08 11:32:06 +0900 (Thu, 08 Apr 2010) New Revision: 27256 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=27256 Log: * lib/yaml.rb (YAML::EngineManager#yamler): set the result after successfully switched. Modified files: trunk/ChangeLog trunk/lib/yaml.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 27255) +++ ChangeLog (revision 27256) @@ -1,3 +1,8 @@ +Thu Apr 8 11:31:37 2010 Nobuyoshi Nakada <nobu@r...> + + * lib/yaml.rb (YAML::EngineManager#yamler): set the result after + successfully switched. + Thu Apr 8 07:22:05 2010 Nobuyoshi Nakada <nobu@r...> * random.c (rand_init): ignore higher bits if all they are same as Index: lib/yaml.rb =================================================================== --- lib/yaml.rb (revision 27255) +++ lib/yaml.rb (revision 27256) @@ -13,7 +13,6 @@ def yamler= engine raise(ArgumentError, "bad engine") unless %w{syck psych}.include?(engine) - @yamler = engine require engine Object.class_eval <<-eorb, __FILE__, __LINE__ + 1 @@ -22,6 +21,8 @@ remove_method :to_yaml alias :to_yaml :#{engine}_to_yaml eorb + + @yamler = engine engine end end -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/