Skip to content

Use stack to track nested closures#6411

Merged
SimplyDanny merged 1 commit intomainfrom
unneeded-escaping
Jan 5, 2026
Merged

Use stack to track nested closures#6411
SimplyDanny merged 1 commit intomainfrom
unneeded-escaping

Conversation

@SimplyDanny
Copy link
Collaborator

Fixes #6410.

@SwiftLintBot
Copy link

93 Messages
📖 Building this branch resulted in a binary size of 27205.98 KiB vs 27205.96 KiB when built on main (0% larger).
📖 Linting Aerial with this PR took 0.77 s vs 0.8 s on main (3% faster).
📖 Linting Alamofire with this PR took 1.03 s vs 1.06 s on main (2% faster).
📖 Linting Brave with this PR took 6.91 s vs 6.89 s on main (0% slower).
📖 Linting DuckDuckGo with this PR took 22.9 s vs 22.86 s on main (0% slower).
📖 Linting Firefox with this PR took 11.08 s vs 11.1 s on main (0% faster).
📖 Linting Kickstarter with this PR took 7.59 s vs 7.63 s on main (0% faster).
📖 Linting Moya with this PR took 0.43 s vs 0.41 s on main (4% slower).
📖 Linting NetNewsWire with this PR took 2.29 s vs 2.29 s on main (0% slower).
📖 Linting Nimble with this PR took 0.67 s vs 0.65 s on main (3% slower).
📖 Linting PocketCasts with this PR took 7.06 s vs 7.02 s on main (0% slower).
📖 Linting Quick with this PR took 0.43 s vs 0.41 s on main (4% slower).
📖 Linting Realm with this PR took 3.32 s vs 3.31 s on main (0% slower).
📖 Linting Sourcery with this PR took 1.81 s vs 1.81 s on main (0% slower).
📖 Linting Swift with this PR took 4.31 s vs 4.31 s on main (0% slower).
📖 Linting SwiftLintPerformanceTests with this PR took 0.36 s vs 0.34 s on main (5% slower).
📖 Linting VLC with this PR took 1.1 s vs 1.14 s on main (3% faster).
📖 Linting Wire with this PR took 17.44 s vs 17.42 s on main (0% slower).
📖 Linting WordPress with this PR took 11.55 s vs 11.54 s on main (0% slower).
📖 This PR fixed a violation in Alamofire: /Source/Core/Session.swift:1235:51: Warning: @escaping attribute not required as 'shouldCreateTask' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Alamofire: /Tests/RequestInterceptorTests.swift:674:76: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Alamofire: /Tests/RequestInterceptorTests.swift:687:95: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Alamofire: /Tests/RequestInterceptorTests.swift:701:94: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/App/BraveWidgets/TopNewsWidget.swift:82:53: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/App/BraveWidgets/TopNewsListWidget.swift:48:53: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/Sources/BraveVPN/Components/InstallVPN/BraveVPNInstallViewController.swift:139:65: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/Sources/BraveWallet/Preview Content/MockKeyringService.swift:90:51: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/UserContent/UserScripts/Scripts_Dynamic/ScriptHandlers/Paged/CosmeticFiltersScriptHandler.swift:37:19: Warning: @escaping attribute not required as 'replyHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/Browser/BrowserViewController/BVC+AIChat.swift:137:44: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/Browser/BrowserViewController/BVC+AIChat.swift:194:49: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Brave: /ios/brave-ios/Sources/Brave/Frontend/Sync/BraveCore/Bookmarks/BookmarkManager.swift:206:69: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/BrowserServicesKit/Autofill/AutofillUserScript+SecureVault.swift:651:78: Warning: @escaping attribute not required as 'replyHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/BrowserServicesKit/Autofill/AutofillUserScript+SecureVault.swift:714:70: Warning: @escaping attribute not required as 'replyHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/BrowserServicesKit/DataImport/TaskWithProgress.swift:114:141: Warning: @escaping attribute not required as 'operation' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/BrowserServicesKit/DataImport/TaskWithProgress.swift:147:165: Warning: @escaping attribute not required as 'operation' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/BrowserServicesKit/DataImport/Logins/SecureVault/SecureVaultLoginImporter.swift:33:117: Warning: @escaping attribute not required as 'progressCallback' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/Crashes/CrashReportSender.swift:53:75: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/Crashes/CrashCollection.swift:64:32: Warning: @escaping attribute not required as 'process' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/Crashes/CrashCollection.swift:65:44: Warning: @escaping attribute not required as 'didFindCrashReports' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/Navigation/DistributedNavigationDelegate.swift:124:39: Warning: @escaping attribute not required as 'decide' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /SharedPackages/BrowserServicesKit/Sources/Navigation/DistributedNavigationDelegate.swift:125:43: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /iOS/AutofillCredentialProvider/CredentialProvider/CredentialProviderViewController.swift:226:69: Warning: @escaping attribute not required as 'provideCredential' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /iOS/DuckDuckGo/UICoordination/UIInteractionManager.swift:50:43: Warning: @escaping attribute not required as 'onAppReadyForInteractions' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /iOS/DuckDuckGo/DuckPlayer/NativeUI/Views/DuckPlayerToastView.swift:73:28: Warning: @escaping attribute not required as 'onDismiss' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /macOS/LocalPackages/XPCHelper/Sources/XPCHelper/XPCClient.swift:113:31: Warning: @escaping attribute not required as 'call' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /macOS/DuckDuckGo/Permissions/Model/PermissionModel.swift:184:54: Warning: @escaping attribute not required as 'decisionHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /macOS/DuckDuckGo/Common/Extensions/TaskWithProgress.swift:114:134: Warning: @escaping attribute not required as 'operation' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /macOS/DuckDuckGo/Common/Extensions/TaskWithProgress.swift:147:158: Warning: @escaping attribute not required as 'operation' does not escape (unneeded_escaping)
📖 This PR fixed a violation in DuckDuckGo: /macOS/scripts/appcast_manager/appcastManager.swift:476:121: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /focus-ios/Blockzilla/Utilities/SearchSuggestClient.swift:14:52: Warning: @escaping attribute not required as 'callback' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /focus-ios/Blockzilla/Siri/SiriShortcuts.swift:60:75: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /focus-ios/Blockzilla/Modules/WebView/LegacyWebViewController.swift:305:34: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/WidgetKit/OpenTabs/TabProvider.swift:20:55: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/WidgetKit/TopSites/TopSitesProvider.swift:26:55: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/Storage/Rust/RustRemoteTabs.swift:220:88: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/Storage/Rust/RustLogins.swift:369:28: Warning: @escaping attribute not required as 'completionHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/Client/Frontend/Library/ClearHistorySheetProvider.swift:88:43: Warning: @escaping attribute not required as 'didComplete' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/Client/Frontend/Library/Bookmarks/Legacy/BookmarksPanelViewModel.swift:223:59: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/Client/Frontend/Browser/SearchEngines/RecentSearchProvider.swift:60:41: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Firefox: /firefox-ios/Client/Frontend/Browser/TopTabDisplayManager.swift:348:41: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Moya: /Sources/Moya/MoyaProvider+Internal.swift:22:116: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Moya: /Sources/Moya/MoyaProvider+Internal.swift:242:162: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in NetNewsWire: /Modules/Account/Sources/Account/Feedly/FeedlyAccountDelegate+OAuth.swift:40:126: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in NetNewsWire: /Modules/Account/Sources/Account/Feedly/FeedlyAccountDelegate+OAuth.swift:72:99: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in PocketCasts: /podcasts/UserEpisodeManager.swift:184:89: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in PocketCasts: /podcasts/AppearanceViewController.swift:165:81: Warning: @escaping attribute not required as 'persistThemeChange' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Wire: /wire-ios-request-strategy/Sources/Request Strategies/User Clients/FetchingClientRequestStrategy.swift:504:28: Warning: @escaping attribute not required as 'completionHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Wire: /wire-ios-request-strategy/Sources/Request Strategies/Conversation/ConversationRequestStrategy.swift:815:28: Warning: @escaping attribute not required as 'completionHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Wire: /wire-ios-request-strategy/Sources/Request Strategies/Conversation/ConversationRequestStrategy.swift:903:28: Warning: @escaping attribute not required as 'completionHandler' does not escape (unneeded_escaping)
📖 This PR fixed a violation in Wire: /wire-ios-sync-engine/Source/Calling/WireCallCenterV3+Events.swift:550:21: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/ViewRelated/Reader/Views/ReaderInterestsCoordinator.swift:42:50: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/ViewRelated/Jetpack/Install/JetpackNativeConnectionService.swift:43:48: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/ViewRelated/Jetpack/Install/JetpackNativeConnectionService.swift:70:39: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/ViewRelated/Menus/Controllers/MenusViewController.swift:9:39: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Services/JetpackCapabilitiesService.swift:28:58: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Services/BloggingPrompts/BloggingPromptsService.swift:146:33: Warning: @escaping attribute not required as 'failure' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Services/BloggingPrompts/BloggingPromptsService.swift:169:34: Warning: @escaping attribute not required as 'failure' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Services/TaxonomyServiceRemoteCoreREST.swift:36:53: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Utility/WebViewController/CookieJar.swift:28:103: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Utility/BackgroundTasks/BackgroundTasksCoordinator.swift:137:36: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Utility/BackgroundTasks/BackgroundTasksCoordinator.swift:191:72: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/Classes/Utility/Notifications/InteractiveNotificationsManager.swift:56:49: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/WordPressShareExtension/Sources/Services/AppExtensionsService.swift:287:54: Warning: @escaping attribute not required as 'requestEnqueued' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /WordPress/WordPressShareExtension/Sources/Services/AppExtensionsService.swift:288:48: Warning: @escaping attribute not required as 'onFailure' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Sources/WordPressAuthenticator/Helpers/UnifiedAuth/ViewRelated/SiteAddress/SiteAddressViewController.swift:458:53: Warning: @escaping attribute not required as 'onCompletion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/WordPressComRestApi.swift:223:54: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/EditorServiceRemote.swift:21:125: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/PluginServiceRemote.swift:12:45: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/PeopleServiceRemote.swift:112:44: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/BlazeServiceRemote.swift:13:79: Warning: @escaping attribute not required as 'callback' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/BlockEditorSettingsServiceRemote.swift:14:33: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/BlockEditorSettingsServiceRemote.swift:31:47: Warning: @escaping attribute not required as 'completion' does not escape (unneeded_escaping)
📖 This PR fixed a violation in WordPress: /Modules/Sources/WordPressKit/ReaderPostServiceRemote+V2.swift:24:37: Warning: @escaping attribute not required as 'success' does not escape (unneeded_escaping)

Generated by 🚫 Danger

@SimplyDanny SimplyDanny merged commit cb578f4 into main Jan 5, 2026
27 checks passed
@SimplyDanny SimplyDanny deleted the unneeded-escaping branch January 5, 2026 09:50
nadeemnali pushed a commit to nadeemnali/SwiftLint that referenced this pull request Feb 26, 2026
nadeemnali pushed a commit to nadeemnali/SwiftLint that referenced this pull request Feb 26, 2026
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.

unneeded_escaping false positive in 0.63.0

2 participants