Files
swift-mirror/test/expr/unary/keypath
Slava Pestov 6c211745f6 Sema: Fix small problem in inferTransitiveKeyPathBindings()
It looks like originally, we would only infer bindings from a
KeyPath type, which has invariant generic arguments. However,
nowadays we can infer a keypath root type from a function
type as well, because we allow keypath to function conversions.

So, if we inferred the key path root type through a function type,
then in fact we cannot introduce it as an exact binding, and
we must preserve variance.

This fixes a test failure that appears with a subsequent change
I'm making.
2026-03-10 14:47:28 -04:00
..