From 344f6beaf2b21462c94fa6de7f2359191245638c Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Tue, 2 Jan 2018 13:07:09 +0100 Subject: [PATCH 1/2] Fix #3452: Add regression tests --- tests/pos/i3452.scala | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 tests/pos/i3452.scala diff --git a/tests/pos/i3452.scala b/tests/pos/i3452.scala new file mode 100644 index 000000000000..c018c386b17d --- /dev/null +++ b/tests/pos/i3452.scala @@ -0,0 +1,18 @@ +object Test { + case class Tuple2K[H[_], T[_], X](h: H[X], t: T[X]) + + trait TC[A] + + implicit def case1[F[_]](implicit t: => TC[F[Any]]): TC[Tuple2K[[_] => Any, F, Any]] = ??? + implicit def case2[A, F[_]](implicit r: TC[F[Any]]): TC[A] = ??? + + implicitly[TC[Int]] // error +} +object Test2 { + trait TC[A] + + implicit def case1[F[_]](implicit t: => TC[F[Any]]): TC[String] = ??? + implicit def case2[G[_]](implicit r: TC[G[Any]]): TC[Int] = ??? + + implicitly[TC[Int]] // error +} From 25d8f8f2cc4349adcefa5a40beabc28422c957fa Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Tue, 2 Jan 2018 13:38:56 +0100 Subject: [PATCH 2/2] Move test to neg --- tests/{pos => neg}/i3452.scala | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename tests/{pos => neg}/i3452.scala (100%) diff --git a/tests/pos/i3452.scala b/tests/neg/i3452.scala similarity index 100% rename from tests/pos/i3452.scala rename to tests/neg/i3452.scala