Closed
Description
Compiler version
3.3.2, 3.4.1, latest main
(20ae563)
Minimized code
import scala.annotation.*
trait X
object Foo:
def foo(using @implicitNotFound("foo!") x: X) = "foo"
object FooClone:
export Foo.foo
object Main:
val n = 10
Foo.foo
FooClone.foo
Output
-- [E172] Type Error: Test.scala:13:9 ------------------------------------------
13 | Foo.foo
| ^
| foo!
-- [E172] Type Error: Test.scala:14:14 -----------------------------------------
14 | FooClone.foo
| ^
|No given instance of type X was found for parameter x of method foo in object FooClone
Note that the FooClone.foo
call no longer emits the custom error message "foo!".
Expectation
Calling FooClone.foo
should properly give the custom error message.
Activity
hamzaremmal commentedon Apr 9, 2024
We are currently working on this issue for the spree with @jan-pieter
Add annotations in parameters for exports (#20140)