[ruby-cvs:70368] kou:r63278 (trunk): rexml: disable XPath 1.0 compatible "#{ELEMENT_NAME}" processing by default

kou at ruby-lang.org kou at ruby-lang.org
Sat Apr 28 10:36:18 JST 2018


kou	2018-04-28 10:36:18 +0900 (Sat, 28 Apr 2018)

  New Revision: 63278

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=63278

  Log:
    rexml: disable XPath 1.0 compatible "#{ELEMENT_NAME}" processing by default
    
    It breaks backward compatibility than I thought. So it's disabled by
    default. It means that REXML's XPath processor isn't compatible with
    XPath 1.0. But it will be acceptable for users.
    
    We can enable it by specifying "strict: true" to
    REXML::XPathParser.new explicitly.
    
    * lib/rexml/xpath.rb,
      lib/rexml/xpath_parser.rb: Accept "strict: true" option.
    
    * test/rexml/test_contrib.rb,
      test/rexml/xpath/test_base.rb: Use not XPath 1.0 compatible behavior.
    
    * test/rexml/test_jaxen.rb: Use XPath 1.0 compatible behavior.
    
    * test/rss/test_1.0.rb,
      test/rss/test_dublincore.rb,
      spec/ruby/library/rexml/element/namespace_spec.rb,
      spec/ruby/library/rexml/element/namespaces_spec.rb,
      spec/ruby/library/rexml/element/prefixes_spec.rb: Enable again.

  Modified files:
    trunk/lib/rexml/xpath.rb
    trunk/lib/rexml/xpath_parser.rb
    trunk/spec/ruby/library/rexml/element/namespace_spec.rb
    trunk/spec/ruby/library/rexml/element/namespaces_spec.rb
    trunk/spec/ruby/library/rexml/element/prefixes_spec.rb
    trunk/test/rexml/test_contrib.rb
    trunk/test/rexml/test_jaxen.rb
    trunk/test/rexml/xpath/test_base.rb
    trunk/test/rss/test_1.0.rb
    trunk/test/rss/test_dublincore.rb


More information about the ruby-cvs mailing list