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
idrougge opened this issue
Sep 4, 2019
· 1 comment
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler in itselffeatureA feature request or implementation
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler in itselffeatureA feature request or implementation
Environment
Xcode 10.3 (10G8), Swift 5
Additional Detail from JIRA
md5: de8ec3fb2fc24920ffff647e79d3f055
Issue Description:
Given a throwing function, e.g.:
Calling it using try? and handling the resulting optional using the ?? operator will not resolve to a non-optional:
…instead giving the error message
…as well as a fixit to replace try? with try!.
In Xcode, the function name will also not be highlighted as a function name until you apply the fixit, turning "try?" into "try!".
Wrapping the call in parentheses, e.g.:
…the code will highlight and compile, but the expression should be solvable without.
The text was updated successfully, but these errors were encountered: