summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--lib/rss/parser.rb14
-rw-r--r--lib/rss/rss.rb29
3 files changed, 6 insertions, 42 deletions
diff --git a/ChangeLog b/ChangeLog
index 4b3354c005..2d2f2f4383 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Tue Feb 6 20:29:44 2007 Kouhei Sutou <kou@cozmixng.org>
+
+ * lib/rss/rss.rb, lib/rss/parser.rb: removed needless code for
+ backward compatibility.
+
Tue Feb 6 18:43:17 2007 Shugo Maeda <shugo@ruby-lang.org>
* lib/net/ftp.rb: moved fixes for EPIPE to the correct
diff --git a/lib/rss/parser.rb b/lib/rss/parser.rb
index e272978992..96be12f748 100644
--- a/lib/rss/parser.rb
+++ b/lib/rss/parser.rb
@@ -1,17 +1,5 @@
require "forwardable"
-begin
- require "open-uri"
-rescue LoadError
- require "uri"
-end
-unless Kernel.methods.include?("URI")
- module Kernel
- def URI(uri_str) # :doc:
- URI.parse(uri_str)
- end
- module_function :URI
- end
-end
+require "open-uri"
require "rss/rss"
diff --git a/lib/rss/rss.rb b/lib/rss/rss.rb
index f424f16171..77a8584884 100644
--- a/lib/rss/rss.rb
+++ b/lib/rss/rss.rb
@@ -30,35 +30,6 @@ class Time
end
end
-module Enumerable
- unless instance_methods.include?("sort_by")
- def sort_by
- collect do |x|
- [yield(x), x]
- end.sort do |x, y|
- x[0] <=> y[0]
- end.collect! do |x|
- x[1]
- end
- end
- end
-end
-
-class Hash
- unless instance_methods.include?("merge")
- def merge(other)
- dup.update(other)
- end
- end
-end
-
-module Kernel
- unless methods.include?("funcall")
- def funcall(*args, &block)
- __send__(*args, &block)
- end
- end
-end
require "English"
require "rss/utils"