Skip to content

Suggest possible imports when reporting a “symbol not found” error #17680

@julienrf

Description

@julienrf

Currently, if you try to apply a method defined as an extension method, but without importing it, the compiler reports and error and suggests you the possible imports that would make the extension method available.

However, the compiler does not suggest you the possible imports you could add to fix “symbol not found” errors (e.g., if you write Monad.apply without first importing cats.Monad).

I believe that would be a useful addition. Many IDEs already do that, but I guess it would be even better if the compiler handled it, and the IDEs could reuse that information directly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions