Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Safar <marek.safar@gmail.com>2009-03-27 19:22:29 +0300
committerMarek Safar <marek.safar@gmail.com>2009-03-27 19:22:29 +0300
commitb1d9489d43df186610426ddae340245ed3271134 (patch)
tree663cb5bb1549880b6a2e68e4e714bc153ddadcb1 /mcs/tests/test-717.cs
parentc4274ee9e8472a5893632c9918098080a623c78f (diff)
New tests.
svn path=/trunk/mcs/; revision=130405
Diffstat (limited to 'mcs/tests/test-717.cs')
-rw-r--r--mcs/tests/test-717.cs60
1 files changed, 60 insertions, 0 deletions
diff --git a/mcs/tests/test-717.cs b/mcs/tests/test-717.cs
new file mode 100644
index 00000000000..3feb2807fac
--- /dev/null
+++ b/mcs/tests/test-717.cs
@@ -0,0 +1,60 @@
+using System;
+
+class AA
+{
+ public virtual int Foo (int i)
+ {
+ return 1;
+ }
+}
+
+abstract class A : AA
+{
+ public int Foo (byte b)
+ {
+ return 2;
+ }
+
+ public override int Foo (int i)
+ {
+ return 4;
+ }
+}
+
+sealed class B : A
+{
+ public override int Foo (int i)
+ {
+ return 3;
+ }
+
+ public void Foo (string s)
+ {
+ }
+}
+
+struct S
+{
+ public override string ToString ()
+ {
+ return "aaaa";
+ }
+}
+
+class MyClass
+{
+ public static int Main ()
+ {
+ S s = new S ();
+ string sss = "a" + s.ToString ();
+
+ B b = new B ();
+ int res = b.Foo (1);
+
+ if (res != 2)
+ return res;
+
+ Console.WriteLine ("OK");
+ return 0;
+ }
+}