Skip to content

Commit de87f50

Browse files
committed
Fix #5256: add regression test
1 parent 3740419 commit de87f50

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

compiler/test/dotty/tools/dotc/CompilationTests.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ class CompilationTests extends ParallelTesting {
171171
@Test def runAll: Unit = {
172172
implicit val testGroup: TestGroup = TestGroup("runAll")
173173
compileFilesInDir("tests/run-custom-args/Yretain-trees", defaultOptions and "-Yretain-trees") +
174+
compileFile("tests/run-custom-args/i5256.scala", allowDeepSubtypes) +
174175
compileFilesInDir("tests/run", defaultOptions)
175176
}.checkRuns()
176177

tests/run-custom-args/i5256.check

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
276

tests/run-custom-args/i5256.scala

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
object Test {
2+
3+
def main(args: Array[String]): Unit = {
4+
val f23: ((Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int)) => Int = {
5+
(x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19, x20, x21, x22, x23) =>
6+
x1 + x2 + x3 + x4 + x5 + x6 + x7 + x8 + x9 + x10 + x11 + x12 + x13 + x14 + x15 + x16 + x17 + x18 + x19 + x20 + x21 + x22 + x23
7+
}
8+
9+
println(f23((1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23)))
10+
}
11+
}

0 commit comments

Comments
 (0)