aboutsummaryrefslogtreecommitdiff
path: root/tests/run/t6126.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/run/t6126.scala')
-rw-r--r--tests/run/t6126.scala8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/run/t6126.scala b/tests/run/t6126.scala
new file mode 100644
index 000000000..c328bf08f
--- /dev/null
+++ b/tests/run/t6126.scala
@@ -0,0 +1,8 @@
+trait LogLevelType
+object Test {
+ type LogLevel = Int with LogLevelType
+ final val ErrorLevel = 1.asInstanceOf[Int with LogLevelType]
+ def main(args: Array[String]): Unit = {
+ List(ErrorLevel, ErrorLevel)
+ }
+}