Skip to content

Commit ff473ba

Browse files
committed
Update test
The new pattern matcher generates switches only for 3 or more cases. Update bytecode tests accordingly.
1 parent 96dd7fd commit ff473ba

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

compiler/test/dotty/tools/backend/jvm/DottyBytecodeTests.scala

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ class TestBCode extends DottyBytecodeTest {
3333
| def foo(i: Int) = i match {
3434
| case 2 => println(2)
3535
| case 1 => println(1)
36+
| case 0 => println(0)
3637
| }
3738
|}""".stripMargin
3839

@@ -54,6 +55,7 @@ class TestBCode extends DottyBytecodeTest {
5455
| def foo(i: Int) = (i: @switch) match {
5556
| case 2 => println(2)
5657
| case 1 => println(1)
58+
| case 0 => println(0)
5759
| }
5860
|}""".stripMargin
5961

0 commit comments

Comments
 (0)