From 04e0609a0685b6e263ece22765ffa1393b5c54ad Mon Sep 17 00:00:00 2001 From: kou Date: Tue, 25 Dec 2018 02:26:30 +0000 Subject: [PATCH] Import REXML 3.1.9 It restores removed REXML::Parsers::BaseParser::UNQME_STR. Because it's used by kramdown. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- NEWS | 2 +- lib/rexml/parsers/baseparser.rb | 4 ++++ lib/rexml/rexml.gemspec | 1 + lib/rexml/rexml.rb | 2 +- 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 02d20c2547..07e8518841 100644 --- a/NEWS +++ b/NEWS @@ -480,7 +480,7 @@ sufficient information, see the ChangeLog file or Redmine [REXML] - * Upgrade to REXML 3.1.8. + * Upgrade to REXML 3.1.9. See https://github.com/ruby/rexml/blob/master/NEWS.md. [Improved some XPath implementations] diff --git a/lib/rexml/parsers/baseparser.rb b/lib/rexml/parsers/baseparser.rb index de337a74d5..39e9ec3fb1 100644 --- a/lib/rexml/parsers/baseparser.rb +++ b/lib/rexml/parsers/baseparser.rb @@ -37,6 +37,10 @@ module REXML QNAME_STR= "(?:(#{NCNAME_STR}):)?(#{NCNAME_STR})" QNAME = /(#{QNAME_STR})/ + # Just for backward compatibility. For example, kramdown uses this. + # It's not used in REXML. + UNAME_STR= "(?:#{NCNAME_STR}:)?#{NCNAME_STR}" + NAMECHAR = '[\-\w\.:]' NAME = "([\\w:]#{NAMECHAR}*)" NMTOKEN = "(?:#{NAMECHAR})+" diff --git a/lib/rexml/rexml.gemspec b/lib/rexml/rexml.gemspec index 8362ca3c3a..6fe7e635f1 100644 --- a/lib/rexml/rexml.gemspec +++ b/lib/rexml/rexml.gemspec @@ -21,6 +21,7 @@ Gem::Specification.new do |spec| ".travis.yml", "Gemfile", "LICENSE.txt", + "NEWS.md", "README.md", "Rakefile", "lib/rexml/attlistdecl.rb", diff --git a/lib/rexml/rexml.rb b/lib/rexml/rexml.rb index 654f54799f..7851c78bf5 100644 --- a/lib/rexml/rexml.rb +++ b/lib/rexml/rexml.rb @@ -24,7 +24,7 @@ module REXML COPYRIGHT = "Copyright © 2001-2008 Sean Russell " DATE = "2008/019" - VERSION = "3.1.8" + VERSION = "3.1.9" REVISION = "" Copyright = COPYRIGHT