periphery
periphery copied to clipboard
False positive: static variable flagged in #Rule macro
I have the following code for tooltips in particular:
@available(iOS 17.0, *)
struct TestTip: Tip {
// swiftlint:disable redundant_type_annotation
@Parameter static var testBool: Bool = false
var rules: [Rule] {
#Rule(Self.$testBool) { $0 }
}
Periphery is registering testBool as unused with
Property 'testBool' is assigned, but never used
It doesn't matter if I use TestTip.testBool or Self.testBool, so I'm wondering if the #Rule is not process correctly.