Skip to content

Commit

Permalink
Add regression test for scala/bug#9220
Browse files Browse the repository at this point in the history
  • Loading branch information
Jasper-M authored Nov 23, 2017
1 parent 6ac6da8 commit 9bc6baa
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
1 change: 1 addition & 0 deletions test/files/pos/t9220.flags
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
-Xfatal-warnings
14 changes: 14 additions & 0 deletions test/files/pos/t9220.scala
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
object Test {
trait Command
object Command {
sealed trait Execution extends Command
}

case class Buzz() extends Command.Execution
case class Door() extends Command.Execution

def foo(cmd: Command.Execution) = cmd match {
case x @ (_: Buzz) => ???
case x @ (_: Door) => ???
}
}

0 comments on commit 9bc6baa

Please sign in to comment.