You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Undo Bogus DiagnosticTransactions in Codable Synthesis
The order of diagnostic emission absolutely does not matter. What this transaction was actually doing was suppressing valid diagnostics. This is a deeply unsound thing to do since if errors are emitted but Codable synthesis succeeds then invalid code can make its way past Sema.
rdar://74392492
Copy file name to clipboardExpand all lines: test/decl/protocol/special/coding/struct_codable_simple.swift
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -31,19 +31,19 @@ let _ = SimpleStruct.encode(to:)
31
31
let _ =SimpleStruct.CodingKeys.self // expected-error {{'CodingKeys' is inaccessible due to 'private' protection level}}
32
32
33
33
// rdar://problem/59655704
34
-
structSR_12248_1:Codable{ // expected-error {{type 'SR_12248_1' does not conform to protocol 'Encodable'}}
34
+
structSR_12248_1:Codable{ // expected-error {{type 'SR_12248_1' does not conform to protocol 'Encodable'}} expected-error {{type 'SR_12248_1' does not conform to protocol 'Decodable'}}
0 commit comments