Commit Graph

1 Commits

Author SHA1 Message Date
Slava Pestov
5ad4fa8b07 SIL: Don't canonicalize struct field and enum element types against the wrong signature
The replacement types of the substitution map are either going
to be contextual types, or interface types using some generic
signature. There is no requirement that this generic signature
is the generic signature of the type declaration itself.

By using the generic signature of the type declaration, we
could incorrectly canonicalize generic parameters to concrete
types if the type itself was defined in a constrained extension,
as in the test case here.

Fixes <rdar://problem/65272763>.
2020-08-11 22:54:19 -04:00