summaryrefslogblamecommitdiff
path: root/test/files/pos/bug704.scala
blob: a05e0a51e7543f231b0d2863fac80b6988d69d05 (plain) (tree)
1
2
3
4
5
         
                                            
                                            
                             
 









                                      
 





                                  
 
trait D {
  private val x = "xxxx should appear twice"
  private object xxxx { Console.println(x) }
  def get_xxxx: AnyRef = xxxx
}

trait E extends D {
  def f(): unit = {
    val y = "yyyy should appear twice"
    object yyyy {
      val x1 = get_xxxx
      Console.println(y)
    }
    yyyy
  }
}
class C extends E {}
object Go extends D {
  def main(args : Array[String]) {
    new C().f()
    new C().f()
  }
}