Closed soumyamahunt closed 1 month ago
Minimal test case:
public struct G<T> where T: P1, T.A: P1, T.A.A: P1 {}
public protocol P1 {
associatedtype A
}
extension Int: P1 {
public typealias A = Int
}
public protocol P2 {
func f()
}
extension G: P2 where T.A == Int {
public func f() {}
}
This is actually not a regression in 6.0, it's just that the verification check is disabled in noassert builds. There's a larger refactoring that needs to happen at some point to define away this problem, but for now I'm going to land a narrower fix.
@slavapestov will this fix land on Swift 6 general release or in 6.1?
Description
If I try to compile Swift package: https://github.com/SwiftyLab/MetaCodable with Swift 5.9 toolchain package is built without errors. When trying to compile with Swift 5.10 following compiler crash occurs:
Reproduction
Stack dump
Expected behavior
Code should compile.
Environment
Swift version 6.0-dev (LLVM fc1036139c5e562, Swift 5bbf725fd958d34) Target: x86_64-unknown-linux-gnu
Additional information
No response