summaryrefslogtreecommitdiff
path: root/test/files
diff options
context:
space:
mode:
authorAdriaan Moors <adriaan.moors@epfl.ch>2009-11-10 16:39:13 +0000
committerAdriaan Moors <adriaan.moors@epfl.ch>2009-11-10 16:39:13 +0000
commitf3a375b0e88508f7c8eb6cf6c47e0fb29e13d49a (patch)
treee50ad2fb9a240e75b325b3c1d191f8a15f868cf8 /test/files
parent277e28956c52435e6d84cea95d67a4cf7c2a1492 (diff)
downloadscala-f3a375b0e88508f7c8eb6cf6c47e0fb29e13d49a.tar.gz
scala-f3a375b0e88508f7c8eb6cf6c47e0fb29e13d49a.tar.bz2
scala-f3a375b0e88508f7c8eb6cf6c47e0fb29e13d49a.zip
test for #2591
Diffstat (limited to 'test/files')
-rw-r--r--test/files/pos/t2591.scala15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/files/pos/t2591.scala b/test/files/pos/t2591.scala
new file mode 100644
index 0000000000..d3c32ba4e9
--- /dev/null
+++ b/test/files/pos/t2591.scala
@@ -0,0 +1,15 @@
+class A
+class B
+
+object Implicits {
+ implicit def imp(x: A): Int = 41
+ implicit def imp(x: B): Int = 41
+}
+
+object Test {
+ // should cause imp to be in scope so that the next expression type checks
+ // `import Implicits._` works
+ import Implicits.imp
+
+ (new A) : Int
+} \ No newline at end of file