Bug 236181

Summary: [WTF] Fix clang tidy bugprone-move-forwarding-reference static analyzer warnings in CompletionHandler.h
Product: WebKit Reporter: David Kilzer (:ddkilzer) <ddkilzer>
Component: Web Template FrameworkAssignee: David Kilzer (:ddkilzer) <ddkilzer>
Status: RESOLVED FIXED    
Severity: Normal CC: benjamin, cdumez, cmarcelo, darin, ews-watchlist, webkit-bug-importer, ysuzuki
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=229114
https://bugs.webkit.org/show_bug.cgi?id=236202
https://bugs.webkit.org/show_bug.cgi?id=236459
Attachments:
Description Flags
Patch v1
ews-feeder: commit-queue-
Patch v2 ysuzuki: review+, ews-feeder: commit-queue-

Description David Kilzer (:ddkilzer) 2022-02-05 12:39:09 PST
Fix clang tidy bugprone-move-forwarding-reference static analyzer warnings in CompletionHandler.h.

Found by clang static analyzer.
Comment 1 Radar WebKit Bug Importer 2022-02-05 12:39:25 PST
<rdar://problem/88529996>
Comment 2 David Kilzer (:ddkilzer) 2022-02-05 12:40:17 PST
Created attachment 450995 [details]
Patch v1
Comment 3 David Kilzer (:ddkilzer) 2022-02-05 13:04:17 PST
Created attachment 450996 [details]
Patch v2
Comment 4 David Kilzer (:ddkilzer) 2022-02-05 13:05:02 PST
(In reply to David Kilzer (:ddkilzer) from comment #2)
> Created attachment 450995 [details]
> Patch v1

Oops.  Changed std::forward() to std::forward<CallableType>().
Comment 5 David Kilzer (:ddkilzer) 2022-02-05 15:05:27 PST
Comment on attachment 450996 [details]
Patch v2

Marking xq+ since enough builds and tests have run to show this didn't cause a regression.
Comment 6 EWS 2022-02-05 15:40:14 PST
Committed r289162 (246858@main): <https://commits.webkit.org/246858@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 450996 [details].
Comment 7 Yusuke Suzuki 2022-02-05 20:16:10 PST
Comment on attachment 450996 [details]
Patch v2

r=me, yes, it can be a lref or rref (b/c CallableType is template type of this function), thus we should use std::forward.
Comment 8 Yusuke Suzuki 2022-02-05 20:16:32 PST
Ah, oops it was already landed.