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
I did recently tweaked the code around casts from a protocol type to a non-protocol type, but my change disabled the diagnostic for situations when we're casting from a protocol type to a non-final class (see #26971), so the first diagnostic should not be produced anymore.
Additional Detail from JIRA
md5: 8b7ddb293d9ac1d4acfdae5edc9c5230
Parent-Task:
Issue Description:
Observed on fairly recent master:
/Volumes/Data/Checkouts/Swift/swift/stdlib/public/Darwin/Foundation/JSONEncoder.swift:928:27: warning: cast from 'Encodable' to unrelated type 'NSDecimalNumber' always fails
return (value as! NSDecimalNumber)
~~~~~ ^ ~~~~~~~~~~~~~~~
/Volumes/Data/Checkouts/Swift/swift/stdlib/public/Darwin/Foundation/JSONEncoder.swift:930:39: warning: cast from 'Encodable' to unrelated type '[String : Encodable]' always fails
return try self.box(value as! [String : Encodable])
~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~
Either the warning is wrong, or this is a bug in the overlay.
The text was updated successfully, but these errors were encountered: