Skip to content

Extension method can be extension_foo #9766

Closed
@bishabosha

Description

@bishabosha

Minimized code

extension (x: Any) def extension_foo: String = "foo"

Output

compiles ok

Expectation

any other definition can not start with extension_, so I would expect this not to work.

the desugared method is extension_extension_foo, should there be an extra check in Desugar for the unexpanded extension method name beginning like that?

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions