Skip to content

Add a compiler quick fix for "Implicit parameters should be provided with a using clause" #23071

@unkarjedy

Description

@unkarjedy

Scala 3.7.0-RC4

This code:

def foo()(implicit x: Int): String = ???

def main(): Unit = {
  foo()(42)
  foo()(42)
  foo()(42)
}

Generates warning:

Implicit parameters should be provided with a `using` clause.
This code can be rewritten automatically under -rewrite -source 3.7-migration.
To disable the warning, please use the following option:
"-Wconf:msg=Implicit parameters should be provided with a `using` clause:s"
Image

It would be nice if the compiler could provide the compiler fix for the warning.

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions