diff options
author | Marek Safar <marek.safar@gmail.com> | 2004-06-21 16:07:23 +0400 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2004-06-21 16:07:23 +0400 |
commit | 8dd59d76593c2d0d9858291b93c9f33b2d388ceb (patch) | |
tree | 22d61b97067f58f27eb6df11432283fced680679 /mcs/errors/cs0660.cs | |
parent | 092ade872e8891a9063fe4c68fa81635f4905ecc (diff) |
new tests
svn path=/trunk/mcs/; revision=30026
Diffstat (limited to 'mcs/errors/cs0660.cs')
-rw-r--r-- | mcs/errors/cs0660.cs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/mcs/errors/cs0660.cs b/mcs/errors/cs0660.cs new file mode 100644 index 00000000000..c2f30957cec --- /dev/null +++ b/mcs/errors/cs0660.cs @@ -0,0 +1,21 @@ +// cs0660.cs: 'T' defines operator == or operator != but does not override Object.Equals(object) +// Line: 5 +// Compiler options: -warnaserror -warn:3 + +class T +{ + public static bool operator == (object o, T t) + { + return false; + } + + public static bool operator != (object o, T t) + { + return true; + } + + public override int GetHashCode () + { + return base.GetHashCode (); + } +} |