-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Open
Labels
enhancementIdeas for improvements of existing features and rules.Ideas for improvements of existing features and rules.rule-requestRequests for a new rules.Requests for a new rules.
Description
New Issue Checklist
- Updated SwiftLint to the latest version
- I searched for existing GitHub issues
Describe the bug
If you disable a <rule> using the disabled_rules configuration key, but still have // swiftlint:disable <rule> in the code, the superfluous_disable_command rule should still report a warning for them.
I didn't complete the rest of the template, because I think it's more of a logic issue than a rule issue, and it's pretty self explanatory, but let me know if you want me to do that.
Complete output when running SwiftLint, including the stack trace and command used
$ swiftlint lintEnvironment
- SwiftLint version (run
swiftlint versionto be sure)? - Installation method used (Homebrew, CocoaPods, building from source, etc)?
- Paste your configuration file:
# insert yaml contents here- Are you using nested configurations?
If so, paste their relative paths and respective contents. - Which Xcode version are you using (check
xcodebuild -version)? - Do you have a sample that shows the issue? Run
echo "[string here]" | swiftlint lint --no-cache --use-stdin --enable-all-rules
to quickly test if your example is really demonstrating the issue. If your example is more
complex, you can useswiftlint lint --path [file here] --no-cache --enable-all-rules.
// This triggers a violation:
let foo = try! bar()Metadata
Metadata
Assignees
Labels
enhancementIdeas for improvements of existing features and rules.Ideas for improvements of existing features and rules.rule-requestRequests for a new rules.Requests for a new rules.