Change shadowing mechanism of extension methods for on par implicit class behavior

This has been a massive substantial* annoyance in converting my libraries to Scala 3.

There are workarounds–define the functionality you want somewhere else and write a dispatcher where everything is in the same scope, for instance–but they are annoying.

Addendum: I think it’s a bit dubious that methods with distinct target names should ever shadow each other. If you can dispatch appropriately, it should work; if not, then you should get an error about ambiguous dispatch.

* (Decided it was better to keep a more neutral perspective.)

2 Likes