-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Support filePrivate
for Private Unit Test Rule in Swift 3
#781
Comments
Any update on |
@bdbergeron I don't know if it's possible for SwiftLint to lint Swift < 3.x sources without itself being Swift 3 (which as far as I can tell it is not yet). In any case, I can probably guess at what the AST keys will be but unless I can run/debug and unit test against Swift 3 I don't see much point. I'm waiting for SwiftLint itself to move to Swift 3 before I can update this rule. There are a number of dependencies that would probably also need to update to Swift 3 before this project (SourceKitten being the most relevant). |
@bdbergeron By the way, can you elaborate on what you mean about |
Sorry for my absence @cfilipov. Slowly trying to work through my backlog of SwiftLint notifications 😅 .
Yes! The Swift version used to build SwiftLint is unrelated to the versions of Swift it can lint! That's because SourceKit is dynamically found and linked. SwiftLint looks for a Swift toolchain in the following order:
SourceKitten has supported Swift 3 essentially since day one, thanks to the same runtime linking mechanism as above, even though its codebase itself was only converted to Swift 3 a few weeks ago. No other dependencies interact with SourceKit, so nothing needs to be updated. I think the "only" things that need to be changed to support |
* commit '83830861d6c6b7fee3218461f699c7d3b457bf2a': refactor isPrivateLevel(identifier:) refactor nameStrippingLeadingUnderscoreIfPrivate combine changelog entries for #781 and #831 Add support for filePrivate and open in rules # Conflicts: # Source/SwiftLintFramework/Extensions/String+SwiftLint.swift # Source/SwiftLintFramework/Rules/MissingDocsRule.swift
#761 has been merged which adds a rule to detect private XCTests (which XCTest will silently not skip). This issue is to serve as a reminder that this rule should be updated when Swift 3 support is added because
filePrivate
has the same effect asprivate
on unit tests.The text was updated successfully, but these errors were encountered: