From 40aafbdf1a9a52c1236f07e06d48fb24b5fa2169 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Sat, 7 Aug 2010 21:06:46 +0000 Subject: Modified r22702 to avoid tarring overloads with... Modified r22702 to avoid tarring overloads with the same brush. No review. --- test/files/neg/bug3736.scala | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'test') diff --git a/test/files/neg/bug3736.scala b/test/files/neg/bug3736.scala index 8e63021f69..cf0920912a 100644 --- a/test/files/neg/bug3736.scala +++ b/test/files/neg/bug3736.scala @@ -8,6 +8,19 @@ object Test { def f6 = super.## } + // Ill-advised overloads to be sure... + class B { + def ##(x: String) = true + def ==(x1: String, xs: List[_]) = true + def !=(x1: String, xs: List[_]) = true + } + + class C extends B { + override def ##(x: String) = super.##(x) + override def ==(x1: String, xs: List[_]) = super.==(x1, xs) + override def !=(x1: String, xs: List[_]) = super.!=(x1, xs) + } + def main(args: Array[String]): Unit = { val x = new A x.f1 -- cgit v1.2.3