From: Sam Ruby Date: 2008-04-10T07:56:17+09:00 Subject: Re: Patch for REXML to fix document writing in 1.9 Dave Thomas wrote: > dave[RUBY3/Book 17:31:22] ruby -vr rexml/document -e > 'REXML::Document.new.write(STDOUT,0)' > > ruby 1.9.0 (2008-04-08 revision 15427) [i686-darwin9.2.2] > /usr/local/rubybook/lib/ruby/1.9.0/rexml/document.rb:187:in `write': > undefined local variable or method `trans' for ... > :REXML::Document (NameError) > from -e:1:in `
' > > I believe the following patch fixes it: > > Index: lib/rexml/document.rb > =================================================================== > --- lib/rexml/document.rb (revision 15929) > +++ lib/rexml/document.rb (working copy) > @@ -184,7 +184,7 @@ > output = Output.new( output, xml_decl.encoding ) > end > formatter = if indent > -1 > - if trans > + if transitive > REXML::Formatters::Transitive.new( indent, ie_hack ) > else > REXML::Formatters::Pretty.new( indent, ie_hack ) Fixed in REXML's repository: http://www.germane-software.com/projects/rexml/changeset/546 Time to resync ruby's svn? - Sam Ruby