-
Notifications
You must be signed in to change notification settings - Fork 10.6k
Description
Previous ID | SR-2921 |
Radar | rdar://problem/28722908 |
Original Reporter | benasher44 (JIRA User) |
Type | Bug |
Status | Closed |
Resolution | Done |
Attachment: Download
Environment
macOS Sierra
Swift 3.0.1
Xcode 8.1b3
Additional Detail from JIRA
Votes | 0 |
Component/s | Compiler |
Labels | Bug, TypeChecker |
Assignee | benasher44 (JIRA) |
Priority | Medium |
md5: 83cc0bca9622db0226c0caa1153a1c2b
relates to:
- SR-2928 Collection casts from collections of optionals to collections of Any need custom handling
Issue Description:
The result from compiling a few different files in our project is warnings emitted in Xcode that look like this:
<unknown>:0: warning: expression implicitly coerced from 'String?' to Any
<unknown>:0: note: provide a default value to avoid this warning
<unknown>:0: note: force-unwrap the value to avoid this warning
<unknown>:0: note: explicitly cast to Any with 'as Any' to silence this warning
<unknown>:0: warning: expression implicitly coerced from 'String?' to Any
<unknown>:0: note: provide a default value to avoid this warning
<unknown>:0: note: force-unwrap the value to avoid this warning
<unknown>:0: note: explicitly cast to Any with 'as Any' to silence this warning
<unknown>:0: warning: expression implicitly coerced from 'String?' to Any
<unknown>:0: note: provide a default value to avoid this warning
<unknown>:0: note: force-unwrap the value to avoid this warning
<unknown>:0: note: explicitly cast to Any with 'as Any' to silence this warning
I've gone through and explicitly unwrapped as many String!/?
s as I can identify, but I can't seem to get these to go away. I've tried coming up with a small repro case, since I can't attach the files in question, but so far I haven't figured out what triggers this. We have about 13 of them like this.