diff options
Diffstat (limited to 'test/files')
-rw-r--r-- | test/files/pos/t9369.flags | 1 | ||||
-rw-r--r-- | test/files/pos/t9369.scala | 24 |
2 files changed, 25 insertions, 0 deletions
diff --git a/test/files/pos/t9369.flags b/test/files/pos/t9369.flags new file mode 100644 index 0000000000..b5a8748652 --- /dev/null +++ b/test/files/pos/t9369.flags @@ -0,0 +1 @@ +-Xfatal-warnings -unchecked diff --git a/test/files/pos/t9369.scala b/test/files/pos/t9369.scala new file mode 100644 index 0000000000..94be2ea4e7 --- /dev/null +++ b/test/files/pos/t9369.scala @@ -0,0 +1,24 @@ +object Test { + + trait Tree + + sealed abstract class Prop + + trait Simple extends Prop + + case class Atom(tree: Tree) extends Prop with Simple + + case class Not(prop: Prop) extends Prop with Simple + + def simplify1(prop: Prop): Prop = prop match { + case Atom(tree) => ??? + case Not(prop) => ??? + case _ => ??? + } + + def simplify2(prop: Prop): Prop = prop match { + case Not(Atom(tree)) => ??? + case Not(Not(prop)) => ??? + case _ => ??? + } +}
\ No newline at end of file |