aboutsummaryrefslogblamecommitdiff
path: root/tests/neg/subtyping.scala
blob: 351fa0ecd55a55af06e25e130d5e65c0b2497dec (plain) (tree)
1
2
3
4
5
6
7
8
9





                 
                       
                                                          
   
                       
                                    
                                                          
   
 
class B {
  class X
}
class A extends B

object Test {
  def test1(): Unit = {
    implicitly[B#X <:< A#X] // error: no implicit argument
  }
  def test2(): Unit = {
    val a : { type T; type U } = ???
    implicitly[a.T <:< a.U] // error: no implicit argument
  }
}