We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3633d62 commit 0ba1238Copy full SHA for 0ba1238
tests/patmat/i12279.scala
@@ -0,0 +1,9 @@
1
+import scala.reflect.Typeable
2
+
3
+def unionTypeTest[T: Typeable](m: Int|T) =
4
+ m match
5
+ case x: Int => println("Got Int")
6
+ case t: T => println("Got T")
7
8
+@main def run =
9
+ unionTypeTest(())
0 commit comments