summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-03-30 11:42:40 -0700
committerPaul Phillips <paulp@improving.org>2012-03-30 11:43:24 -0700
commit75e584bd0c056a39ea6ef52848e8c2cbe764cb3a (patch)
tree36946236c7d36217e2e6f124260c53eddba171a3 /test
parent0fae7b9064e44b3ee8041a5e5a19e85abfb32e0c (diff)
downloadscala-75e584bd0c056a39ea6ef52848e8c2cbe764cb3a.tar.gz
scala-75e584bd0c056a39ea6ef52848e8c2cbe764cb3a.tar.bz2
scala-75e584bd0c056a39ea6ef52848e8c2cbe764cb3a.zip
Fix for regression with inference at arity 21+.
A classic "off by two" error. Closes SI-4545, SI-5633.
Diffstat (limited to 'test')
-rw-r--r--test/files/pos/t4545.scala14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/files/pos/t4545.scala b/test/files/pos/t4545.scala
new file mode 100644
index 0000000000..8c7a3236c4
--- /dev/null
+++ b/test/files/pos/t4545.scala
@@ -0,0 +1,14 @@
+object Test {
+ def f[A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T](table: Tuple20[A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T])(fun: (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T) => Unit) {
+ }
+ def g[A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U](table: Tuple21[A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U])(fun: (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U) => Unit) {
+ }
+
+ def g20 = f(
+ ( 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1)
+ ) { case ((a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t)) => () }
+
+ def g21 = g(
+ (1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1)
+ ) { case ((a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u)) => () }
+}