Skip to content

Commit 3c65cfc

Browse files
Update Source/SwiftLintBuiltInRules/Rules/Lint/VariableShadowingRule.swift
Co-authored-by: Danny Mösch <danny.moesch@icloud.com>
1 parent 84ea655 commit 3c65cfc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Source/SwiftLintBuiltInRules/Rules/Lint/VariableShadowingRule.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ private extension VariableShadowingRule {
7373
final class Visitor: DeclaredIdentifiersTrackingVisitor<ConfigurationType> {
7474
override func visit(_ node: VariableDeclSyntax) -> SyntaxVisitorContinueKind {
7575
// Early exit for member blocks (class/struct properties)
76-
if node.parent?.is(MemberBlockItemSyntax.self) != true {
76+
if node.parent?.is(MemberBlockItemSyntax.self) == false {
7777
// Check for shadowing BEFORE adding to scope
7878
node.bindings.forEach { binding in
7979
checkForShadowing(in: binding.pattern)

0 commit comments

Comments
 (0)