Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
False positives when using explicit_type_interface with allowRedundancy #2425
Using the lastest SwiftLint version, when I use the rule
explicit_type_interface: allow_redundancy: true
most of the cases are handled correctly. But for some initializers Swift has some sugar syntax integrated and some initializers might throw. In both cases this option doesn't work correctly.
Specifically, the following three lines are shown as warnings but shouldn't:
let regex = try! NSRegularExpression(pattern: ".*") let array = [String]() let dict = [String: String]()