Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Respect array types in redundant_type_annotation rule #5536

Merged
merged 1 commit into from
Apr 21, 2024

Conversation

SimplyDanny
Copy link
Collaborator

@SimplyDanny SimplyDanny commented Apr 21, 2024

Fixes #3141.

Also try to change the implementation slightly by focusing on the important aspects of the rule (i.e. extracting type names) in separate methods.

@SwiftLintBot
Copy link

22 Warnings
⚠️ This PR may need tests.
⚠️ This PR introduced a violation in Aerial: /Aerial/Source/Views/AerialView.swift:20:23: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Brave: /Sources/Brave/Frontend/Browser/Tabs/TabTray/Views/TabTrayCell.swift:33:14: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Autofill/CreditCard/CreditCardBottomSheet/CreditCardBottomSheetViewModel.swift:78:26: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Autofill/CreditCard/CreditCardSettingsView/CreditCardTableViewModel.swift:14:20: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Home/JumpBackIn/Data/JumpBackInDataAdaptor.swift:26:27: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Home/JumpBackIn/JumpBackInViewModel.swift:34:19: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Library/Downloads/DownloadsPanel.swift:24:27: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Library/ReaderPanel.swift:183:27: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Frontend/Library/RecentlyClosedTabsPanel.swift:30:27: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/TabManagement/Tab.swift:120:28: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/TabManagement/Tab.swift:125:36: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Firefox: /firefox-ios/Client/Utils/SearchTermGroupsUtility.swift:125:26: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Kickstarter: /Kickstarter-iOS/Features/Discovery/Views/Cells/DiscoveryProjectCardCell.swift:22:39: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Kickstarter: /Library/ViewModels/CategorySelectionViewModel.swift:177:28: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in NetNewsWire: /Shared/Activity/ActivityManager.swift:140:11: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in VLC: /Sources/Playback/Control/VLCRendererDiscovererManager.swift:20:26: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in VLC: /Sources/Playback/Control/VLCRendererDiscovererManager.swift:39:30: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Wire: /wire-ios-cryptobox/WireCryptobox/ChaCha20Poly1305/StreamEncryption.swift:92:25: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Wire: /wire-ios-cryptobox/WireCryptobox/ChaCha20Poly1305/StreamEncryption.swift:93:25: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in Wire: /wire-ios/Wire-iOS/Sources/UserInterface/Collections/CollectionViewLeftAlignedFlowLayout.swift:33:26: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
⚠️ This PR introduced a violation in WordPress: /WordPress/Classes/ViewRelated/Blog/SharingButtonsViewController.swift:777:17: warning: Redundant Type Annotation Violation: Variables should not have redundant type annotation (redundant_type_annotation)
17 Messages
📖 Linting Aerial with this PR took 0.18s vs 0.17s on main (5% slower)
📖 Linting Alamofire with this PR took 0.16s vs 0.16s on main (0% slower)
📖 Linting Brave with this PR took 0.68s vs 0.68s on main (0% slower)
📖 Linting DuckDuckGo with this PR took 0.54s vs 0.54s on main (0% slower)
📖 Linting Firefox with this PR took 1.19s vs 1.19s on main (0% slower)
📖 Linting Kickstarter with this PR took 0.75s vs 0.75s on main (0% slower)
📖 Linting Moya with this PR took 0.11s vs 0.11s on main (0% slower)
📖 Linting NetNewsWire with this PR took 0.29s vs 0.29s on main (0% slower)
📖 Linting Nimble with this PR took 0.13s vs 0.13s on main (0% slower)
📖 Linting PocketCasts with this PR took 0.66s vs 0.65s on main (1% slower)
📖 Linting Quick with this PR took 0.1s vs 0.1s on main (0% slower)
📖 Linting Realm with this PR took 0.52s vs 0.51s on main (1% slower)
📖 Linting Sourcery with this PR took 0.31s vs 0.32s on main (3% faster)
📖 Linting Swift with this PR took 0.44s vs 0.44s on main (0% slower)
📖 Linting VLC with this PR took 0.18s vs 0.18s on main (0% slower)
📖 Linting Wire with this PR took 1.74s vs 1.73s on main (0% slower)
📖 Linting WordPress with this PR took 1.05s vs 1.05s on main (0% slower)

Generated by 🚫 Danger

@SimplyDanny SimplyDanny enabled auto-merge (squash) April 21, 2024 17:36
@SimplyDanny SimplyDanny merged commit e643f21 into realm:main Apr 21, 2024
12 checks passed
@SimplyDanny SimplyDanny deleted the array-types branch April 21, 2024 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

redundant_type_annotation ignores arrays
2 participants