merging the Mainsoft branch to the trunk
[mono.git] / mcs / class / System / System.ComponentModel / AttributeCollection.cs
index 1221270f082eb04206d77102da0387dd20d6df27..658117ac1af0982a8042209ee40985fa39bad2e7 100644 (file)
@@ -56,7 +56,11 @@ namespace System.ComponentModel
 
                public bool Contains (Attribute attr)
                {
-                       return attrList.Contains (attr);
+                       Attribute at = this [attr.GetType ()];
+                       if (at != null)
+                               return attr.Equals (at);
+                       else
+                               return false;
                }
 
                public bool Contains (Attribute [] attributes)