From 3a7a92bd9263a932c5a3f64307641b374923580a Mon Sep 17 00:00:00 2001 From: Jason Zaugg Date: Sat, 12 May 2012 07:15:40 +0200 Subject: Test case closes SI-4124. This looks like a job for... virtpatmat! --- test/files/run/t4124.check | 4 ++++ test/files/run/t4124.scala | 24 ++++++++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 test/files/run/t4124.check create mode 100644 test/files/run/t4124.scala (limited to 'test/files') diff --git a/test/files/run/t4124.check b/test/files/run/t4124.check new file mode 100644 index 0000000000..66a0092d93 --- /dev/null +++ b/test/files/run/t4124.check @@ -0,0 +1,4 @@ +hi +hi +bye +bye diff --git a/test/files/run/t4124.scala b/test/files/run/t4124.scala new file mode 100644 index 0000000000..9f35b57ce3 --- /dev/null +++ b/test/files/run/t4124.scala @@ -0,0 +1,24 @@ +import xml.Node + +object Test extends App { + val body: Node = hi + 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" + }) +} -- cgit v1.2.3