projects
/
mono.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[xbuild] Use the env var $MSBuildExtensionsPath before trying other paths.
[mono.git]
/
mcs
/
tests
/
test-342.cs
diff --git
a/mcs/tests/test-342.cs
b/mcs/tests/test-342.cs
index b4b9fcc6f08d966348ee50a6829e103df94301b4..b40598cff4907ef70a80a028ca180b6d6d70072e 100644
(file)
--- a/
mcs/tests/test-342.cs
+++ b/
mcs/tests/test-342.cs
@@
-6,6
+6,15
@@
class A {
public virtual void Foo (double d) {
throw new Exception ("Shouldn't be invoked");
}
public virtual void Foo (double d) {
throw new Exception ("Shouldn't be invoked");
}
+
+ public virtual bool this [int i] {
+ get { return true; }
+ }
+
+ public virtual bool this [double d] {
+ get { throw new Exception ("Shouldn't be invoked"); }
+ }
+
}
class B : A {
}
class B : A {
@@
-13,7
+22,12
@@
class B : A {
throw new Exception ("Overload resolution failed");
}
throw new Exception ("Overload resolution failed");
}
+ public override bool this [double d] {
+ get { throw new Exception ("Overload resolution failed"); }
+ }
+
public static void Main () {
new B ().Foo (1);
public static void Main () {
new B ().Foo (1);
+ bool b = new B () [1];
}
}
}
}