We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
e.g.: let app = NSApp.delegate as! AppDelegate Issue: error: Force Cast Violation (High Severity): Force casts should be avoided
let app = NSApp.delegate as! AppDelegate
error: Force Cast Violation (High Severity): Force casts should be avoided
e.g.: let app = (NSApp.delegate as? AppDelegate)! Issue: none, it passes
let app = (NSApp.delegate as? AppDelegate)!
Is this the expected behavior?
The text was updated successfully, but these errors were encountered:
The force cast rule only checks for as!. You're welcome to write a force unwrap rule.
as!
Sorry, something went wrong.
Closing as a duplicate of #55.
No branches or pull requests
e.g.:
let app = NSApp.delegate as! AppDelegate
Issue:
error: Force Cast Violation (High Severity): Force casts should be avoided
e.g.:
let app = (NSApp.delegate as? AppDelegate)!
Issue: none, it passes
Is this the expected behavior?
The text was updated successfully, but these errors were encountered: