We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
class Foo(x: Int) { private[this] var init = false; lazy val foo = { if (!init) { init = true assert(false) } x } } object Test { def main(args: Array[String]): Unit = { val foo = new Foo(42) try foo.foo catch { case _: AssertionError => println(foo.foo) // prints 0, should be 42 } } }