mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Previously we were introducing a type variable to mark a constructor's parameter list as `TVO_PrefersSubtypeBinding`. Unfortunately this relies on representing the parameter list as a tuple, which will no longer be properly supported once param flags are removed from tuple types. Move the logic into CSRanking such that we pick up and compare the parameter lists when comparing overload bindings. For now, this still relies on comparing the parameter lists as tuples, as there's some subtle tuple subtyping rules that could potentially affect source compatibility here, but at least we can explicitly strip the parameter flags and localise the hack to CSRanking rather than exposing it as a constraint.
480 KiB
480 KiB