You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given
```scala
trait Sel extends Dynamic
extension (s: Sel)
def selectDynamic(name: String) = ???
```
the following worked:
```scala
val sel = new Sel {}
val foo = sel.foo
```
but the following didn't:
```scala
val sel2 = (new Sel {}).asInstanceOf[Sel{ def foo: String }]
val foo2 = sel2.foo
```
The problem was that we recognized a structural dispatch and then required
the qualifier to be an instance of `Selectable`. But in fact, `Dynamic`
works just as well, and the mechanism is the same. It's just that
`Dynamic` is less type safe then `Selectable`.
0 commit comments