diff options
author | marcandre <marcandre@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-12-24 07:33:24 +0000 |
---|---|---|
committer | marcandre <marcandre@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-12-24 07:33:24 +0000 |
commit | dbb14e218a7c9dd9ad64fec0ae969cbb2d262f4c (patch) | |
tree | 9c55dd09d9c9cf0040533e8e17b90e4981dd2ce1 | |
parent | c80535e50d9ad833d4027dd7bf1a1fc4708bc123 (diff) | |
download | ruby-dbb14e218a7c9dd9ad64fec0ae969cbb2d262f4c.tar.gz |
* lib/uri/generic.rb (eql?): Check the class of the compared object.
Based on a patch by Peter McLain [ruby-core:27019]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | lib/uri/generic.rb | 1 |
2 files changed, 6 insertions, 0 deletions
@@ -1,3 +1,8 @@ +Thu Dec 24 16:32:30 2009 Marc-Andre Lafortune <ruby-core@marc-andre.ca> + + * lib/uri/generic.rb (eql?): Check the class of the compared object. + Based on a patch by Peter McLain [ruby-core:27019] + Thu Dec 24 15:20:03 2009 NARUSE, Yui <naruse@ruby-lang.org> * regexec.c (match_at): follow enclen's change. diff --git a/lib/uri/generic.rb b/lib/uri/generic.rb index fd01f89797..1ca970de74 100644 --- a/lib/uri/generic.rb +++ b/lib/uri/generic.rb @@ -1066,6 +1066,7 @@ module URI end def eql?(oth) + self.class == oth.class && parser == oth.parser && self.component_ary.eql?(oth.component_ary) end |