* lib/rss/rss.rb, lib/rss/parser.rb: followed current Ruby

specification. [ruby-dev:30274]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11645 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
kou 2007-02-06 11:38:13 +00:00
parent cbcb626ee5
commit 8bc63849d5
3 changed files with 8 additions and 3 deletions

View File

@ -1,3 +1,8 @@
Tue Feb 6 20:36:19 2007 Kouhei Sutou <kou@cozmixng.org>
* lib/rss/rss.rb, lib/rss/parser.rb: followed current Ruby
specification. [ruby-dev:30274]
Tue Feb 6 20:29:44 2007 Kouhei Sutou <kou@cozmixng.org>
* lib/rss/rss.rb, lib/rss/parser.rb: removed needless code for

View File

@ -218,7 +218,7 @@ module RSS
def def_get_text_element(uri, name, file, line)
register_uri(uri, name)
unless private_instance_methods(false).include?("start_#{name}")
unless private_instance_methods(false).include?("start_#{name}".to_sym)
module_eval(<<-EOT, file, line)
def start_#{name}(name, prefix, attrs, ns)
uri = ns[prefix]

View File

@ -25,7 +25,7 @@ class Time
end
end
unless instance_methods.include?("w3cdtf")
unless method_defined?(:w3cdtf)
alias w3cdtf iso8601
end
end
@ -783,7 +783,7 @@ EOC
def other_element(need_convert, indent='')
rv = []
private_methods.each do |meth|
if /\A([^_]+)_[^_]+_elements?\z/ =~ meth and
if /\A([^_]+)_[^_]+_elements?\z/ =~ meth.to_s and
self.class::NSPOOL.has_key?($1)
res = __send__(meth, need_convert, indent)
rv << res if /\A\s*\z/ !~ res