mirror of
https://github.com/realm/SwiftLint.git
synced 2026-06-06 20:18:40 +00:00
a70e4bd759
There is at least one semi-common case where capitalized names should probably be allowed: in OptionSetType classes, the standard pattern is to use `static let = Foo` to declare each option for the type. Apple docs demostrating this: https://developer.apple.com/library/prerelease/ios/documentation/Swift/Reference/Swift_OptionSetType_Protocol/index.html One downside of this implementation is that it would *also* pass a capitalized "static var Foo", which is probably not desirable. It's not clear to me how feasible addressing this is: it seems like SourceKitten might need to be updated to support this better? Using `static var` at all is code smell, though, so hopefully this isn't a huge deal. Perhaps there should even be a rule identifying `static var` and considering it a violation?