mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
The small-but-significant change to the generic signature builder is to refuse to create unresolved potential archetypes. Instead, delay any requirement that depends on such type, to be reprocessed once we've seen all of the other requirements. If the type can be resolved later, it will be; Otherwise, the type checker will complain when it sees an unresolvable type. By itself, this fixes the crash in SR-2796. Doing this by itself regresses diagnostics because typo correction in the generic signature builder no longer kicks in. Therefore, implement typo correction for these cases in the type checker proper, using its existing facilities for typo correction. The result is more consistent code with a better result. Fixes SR-2796 / rdar://problem/28544316.