aboutsummaryrefslogtreecommitdiff
path: root/tests/pending/run/t4124.scala
blob: 79bcf55f01b1e1d8dc605139a1260f366844e638 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import xml.Node

object Test extends dotty.runtime.LegacyApp {
  val body: Node = <elem>hi</elem>	
  println ((body: AnyRef, "foo") match {
    case (node: Node, "bar")        => "bye"
    case (ser: Serializable, "foo") => "hi"
  })

  println ((body, "foo") match {
    case (node: Node, "bar")        => "bye"
    case (ser: Serializable, "foo") => "hi"
  })

  println ((body: AnyRef, "foo") match {
    case (node: Node, "foo")        => "bye"
    case (ser: Serializable, "foo") => "hi"
  })

  println ((body: AnyRef, "foo") match {
    case (node: Node, "foo")        => "bye"
    case (ser: Serializable, "foo") => "hi"
  })
}