aboutsummaryrefslogblamecommitdiff
path: root/tests/pos/sigs.scala
blob: 4af4bda90297e79b6937ee25423a22caee683cab (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11

             



                       




                             









                                   

















                            

 
 
object sigs {
  
  type Lst[A] = List[A]
  
  type Twin[B] = (B, B)
  
  var x = 7 * 9
  
  class Base {
    
    def foo(x: Int): Any = 33
    def foo: Object = "x"
    
  }
  
  class Sub extends Base {
    
   override def foo = "abc"
      
   override def foo(x: Int) = "abc"
  }
  
  trait A { self: B =>
    type AA
    val a: AA & BB
    
  }
  
  trait B { this: A =>
    type BB
    val b: AA & BB
  }

  class C extends A with B {
    type AA = String
    type BB = AnyRef
    val a = ""
    val b = ""
  }


}