diff options
Diffstat (limited to 'tests/pos')
-rw-r--r-- | tests/pos/overrides.scala | 2 | ||||
-rw-r--r-- | tests/pos/synthetics.scala | 8 | ||||
-rw-r--r-- | tests/pos/t0599.scala | 4 | ||||
-rw-r--r-- | tests/pos/t2809.scala | 2 |
4 files changed, 12 insertions, 4 deletions
diff --git a/tests/pos/overrides.scala b/tests/pos/overrides.scala index 3d254ea70..97402f773 100644 --- a/tests/pos/overrides.scala +++ b/tests/pos/overrides.scala @@ -6,7 +6,7 @@ class A[T] { class B extends A[Int] { - def f(x: Int)(y: Int) = y + override def f(x: Int)(y: Int) = y f(2)() diff --git a/tests/pos/synthetics.scala b/tests/pos/synthetics.scala index c7d49df70..c870cb1a4 100644 --- a/tests/pos/synthetics.scala +++ b/tests/pos/synthetics.scala @@ -2,3 +2,11 @@ case class C(x: Int, var y: String) { } + +class Top { + + final override def hashCode: Int = 2 + +} + +case class Sub() extends Top diff --git a/tests/pos/t0599.scala b/tests/pos/t0599.scala index 885159af6..6445fa9fb 100644 --- a/tests/pos/t0599.scala +++ b/tests/pos/t0599.scala @@ -7,8 +7,8 @@ abstract class FooA { } } trait FooB extends FooA { - type A <: Ax; - trait Ax extends super.Ax { def xxx : Int; } + type A <: Axx; + trait Axx extends super.Ax { def xxx : Int; } abstract class InnerB extends InnerA { // type B <: A; val a : A = doB; diff --git a/tests/pos/t2809.scala b/tests/pos/t2809.scala index 1f68b0b07..1e9ec60d2 100644 --- a/tests/pos/t2809.scala +++ b/tests/pos/t2809.scala @@ -12,7 +12,7 @@ package p2 { // all being in the same package compiles fine } abstract class T3 extends T2 { - class A { + class A2 { bug() } } |