Commit Graph

8 Commits

Author SHA1 Message Date
JP Simard 8d734366fb Remove unused private declarations (#2386) 2018-09-03 16:45:02 -07:00
JP Simard dcc85fb0f3 Remove unused imports (#2382) 2018-09-02 14:09:04 -07:00
JP Simard 2bcea4b04d Add ability for SwiftLint to lint files with full type-checked AST awareness (#2379)
* Add LintableFilesVisitor

* Move LintCommand logic into LintOrAnalyzeCommand

to prepare for the upcoming analyze command

* Add AnalyzeCommand (not fully implemented yet in SwiftLintFramework)

* Add analyzerRules configuration member

* Add AnalyzerRule protocol

* Pass compiler arguments to validate/correct

* Add requiresFileOnDisk member to RuleDescription

This will be used by AnalyzerRules because they need a file on disk
to pass in the compiler arguments to SourceKit.

* Exclusively run AnalyzerRules when the Linter has compiler arguments

* Enable testing AnalyzerRules in TestHelpers

* Add ExplicitSelfRule

* Update documentation

* Fix `analyze --autocorrect`

* Improve performance of CompilerArgumentsExtractor

* Fix lint command actually running analyze

* Move File operations in TestHelpers into a private extension

* Add analyzer column to rules command and markdown documentation

* Use a Set literal

* Make AnalyzerRule inherit from OptInRule

* Mention analyzer_rules in readme

* Mention that analyzer rules are slow
2018-09-02 00:13:27 -07:00
Marcelo Fabri 881978ea26 Fix crash on multiline_function_chains rule
Fixes #2360
2018-08-23 21:10:56 -07:00
Marcelo Fabri 32164501e1 Merge pull request #2339 from marcelofabri/multiple_closures_with_trailing_closure-performance
Improve performance of multiple_closures_with_trailing_closure
2018-08-08 09:37:38 -07:00
Marcelo Fabri 5b3145a448 Improve performance of multiple_closures_with_trailing_closure 2018-08-08 08:50:23 -07:00
Marcelo Fabri 30fe00890c Fix comma rule false positives on object literals
Fixes #2345
2018-08-08 08:47:17 -07:00
JP Simard 3961d6482b Organize rules by kind in Xcode project (#2341) 2018-08-05 18:54:05 -07:00