diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-06 00:22:04 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-06 00:22:04 +0000 |
commit | 75ba1d6ac49db4847877c41f50da48d18423c15b (patch) | |
tree | 931143484f5caf456714681818430baeb0833826 | |
parent | 9ea41e083c6dca6f75d1f1e8cf51686fd6784de5 (diff) | |
download | ruby-75ba1d6ac49db4847877c41f50da48d18423c15b.tar.gz |
Fix previous commit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27231 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | lib/rexml/parsers/baseparser.rb | 3 | ||||
-rw-r--r-- | lib/rss/parser.rb | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/rexml/parsers/baseparser.rb b/lib/rexml/parsers/baseparser.rb index f108ea2d32..053ac6441e 100644 --- a/lib/rexml/parsers/baseparser.rb +++ b/lib/rexml/parsers/baseparser.rb @@ -32,10 +32,11 @@ module REXML EXTENDER = '' # TODO NCNAME_STR= "[#{LETTER}_:][-.\w:#{COMBININGCHAR}#{EXTENDER}]*" + NCNAME_STR= "[#{LETTER}_:][-[:alnum:]._:#{COMBININGCHAR}#{EXTENDER}]*" NAME_STR= "(?:(#{NCNAME_STR}):)?(#{NCNAME_STR})" UNAME_STR= "(?:#{NCNAME_STR}:)?#{NCNAME_STR}" - NAMECHAR = '[\-\w:]' + NAMECHAR = '[\-\w\.:]' NAME = "([\\w:]#{NAMECHAR}*)" NMTOKEN = "(?:#{NAMECHAR})+" NMTOKENS = "#{NMTOKEN}(\\s+#{NMTOKEN})*" diff --git a/lib/rss/parser.rb b/lib/rss/parser.rb index 1a9e71ea57..c426a187b8 100644 --- a/lib/rss/parser.rb +++ b/lib/rss/parser.rb @@ -417,7 +417,7 @@ module RSS end end - NAMESPLIT = /^(?:([\w:][-\w\d.]*):)?([\w:][-\w\d.]*)/ + NAMESPLIT = /^(?:([\w:][-\w.]*):)?([\w:][-\w.]*)/ def split_name(name) name =~ NAMESPLIT [$1 || '', $2] |