Remove trait-private-var test from sbt/sbt

This commit is contained in:
Eugene Yokota 2016-05-05 23:44:11 -04:00
parent e3560e4ed6
commit f2ad99594e
4 changed files with 0 additions and 25 deletions

View File

@ -1,3 +0,0 @@
trait A {
def bar: Int = 0
}

View File

@ -1,3 +0,0 @@
object B extends A {
def main(args: Array[String]): Unit = println(bar)
}

View File

@ -1,5 +0,0 @@
trait A {
private var foo = 12
// we need to access foo to trigger AbstractMethodError
def bar: Int = foo
}

View File

@ -1,14 +0,0 @@
# compile and run for the first time to verify that everything works
> run
# introduce private var and refer to it in a trait that we inherit from
# there'll be pair of getters and setters generated for private var that
# has to be implemented by a class (where you can declare corresponding field)
$ copy-file changes/A.scala A.scala
# this fails with AbstractMethodError because getters and setters for
# a private var are not generated because introduction of a private var
# does not trigger recompilation of B
# B is not recompiled because incremental compiler tracks only public
# interace (members visible from outside of given trait/class)
> run