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:
authorMiguel de Icaza <miguel@gnome.org>2003-05-09 21:33:11 +0400
committerMiguel de Icaza <miguel@gnome.org>2003-05-09 21:33:11 +0400
commitbe610e10feeea2baa9740ea881618e530d14321a (patch)
tree8388cb6ddf66509da188e9362bca827071b9dd5a /mcs/tests/test-15.cs
parent845923bbfb2d00df8183dced542ea571753799bb (diff)
Improve test
svn path=/trunk/mcs/; revision=14425
Diffstat (limited to 'mcs/tests/test-15.cs')
-rwxr-xr-xmcs/tests/test-15.cs18
1 files changed, 16 insertions, 2 deletions
diff --git a/mcs/tests/test-15.cs b/mcs/tests/test-15.cs
index c199bc13bcb..98769e46f29 100755
--- a/mcs/tests/test-15.cs
+++ b/mcs/tests/test-15.cs
@@ -1,13 +1,20 @@
using System;
interface Iface {
- void A ();
+ int A ();
}
class Implementor : Iface {
- public void A () {}
+ public int A () {
+ return 1;
+ }
}
+struct StructImplementor : Iface {
+ public int A () {
+ return 2;
+ }
+}
class Run {
static int Main ()
@@ -16,6 +23,13 @@ class Run {
Implementor i = new Implementor ();
iface = i;
+ if (iface.A () != 1)
+ return 1;
+
+ StructImplementor s = new StructImplementor ();
+ Iface xiface = (Iface) s;
+ if (iface.A () != 2)
+ return 2;
return 0;
}