Skip to content

Commit 21b2f5a

Browse files
authored
Polishing
1 parent 4ac25fa commit 21b2f5a

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed
Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
object Testi4674 {
2-
def T(x: String) = {
1+
class Test {
2+
def test(x: String) = {
33
x.foreach {
44
case 's' => println("s")
5-
case c: Char => println(c) // error
5+
case c: Char => println(c) // error: type test always succeeds
66
}
77
}
8-
T("test")
9-
}
8+
}

0 commit comments

Comments
 (0)