Repository navigation
[DO NOT MERGE] Add return_value_from_void_function using SwiftSyntax - #3015
marcelofabri wants to merge 2 commits into
Conversation
Couldn't we instead either 1) add a podspec for SwiftSyntax or 2) conditionally use SwiftSyntax when available by using |
We could, but not sure if it's worth the complexity/extra work in the first option and in the long term I imagine that we'd have more and more rules using |
|
Neither approach seem particularly time-consuming to me. |
|
Swift is pretty good at handling old syntax, so using the latest seems fine for linting all Swift versions going back to 3.0.
It'd be awesome to get rid of our |
The issue is not linting old Swift versions, but compiling SwiftLint itself (see CI for this PR, e.g. the "SwiftPM xcode103" job).
That's a good idea, as it (apparently) supports using dependencies from SPM! |
|
This is my suggestion to move forward:
|
|
Closing in favor of #3054 |
Used #2480 as a starting point
This is an example of a rule that SwiftSyntax enables us to write with not too much code and in a reliable way.
Added "DO NOT MERGE" because there are a few drawbacks of adding SwiftSyntax and we should address those separately first:
SwiftSyntaxvia CocoaPods, so we'd have to deprecateSwiftLintFramework.podspecswift package generate-xcodeprojmight have changed important settings (e.g. deployment target)