Skip to content

Commit 656c2b6

Browse files
committed
Fix test failure on Java 11
1 parent 07ae23c commit 656c2b6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tests/run/t6827.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ object Test extends App {
88
it.copyToArray(arr, start, len)
99
"ok"
1010
} catch {
11+
case e: ArrayIndexOutOfBoundsException =>
12+
// Special-case printing this exception because the toString changed in Java 11
13+
s"ArrayIndexOutOfBoundsException: ${e.index}"
1114
case e: Exception => e.toString
1215
}
1316
println("%s: %s" format (label, status))

0 commit comments

Comments
 (0)