aboutsummaryrefslogtreecommitdiff
path: root/tests/pending/pos/t4975.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/pending/pos/t4975.scala')
-rw-r--r--tests/pending/pos/t4975.scala12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/pending/pos/t4975.scala b/tests/pending/pos/t4975.scala
new file mode 100644
index 000000000..3339631dc
--- /dev/null
+++ b/tests/pending/pos/t4975.scala
@@ -0,0 +1,12 @@
+object ImplicitScope {
+ class A[T]
+
+ def foo: Unit = {
+ trait B
+ object B {
+ implicit def ab: ImplicitScope.A[B] = new A[B]
+ }
+
+ implicitly[A[B]] // Error
+ }
+}