RESOLVED FIXED 229114
[WTF] Fix static analyzer warnings for clang tidy bugprone-move-forwarding-reference checker
https://bugs.webkit.org/show_bug.cgi?id=229114
Summary [WTF] Fix static analyzer warnings for clang tidy bugprone-move-forwarding-re...
David Kilzer (:ddkilzer)
Reported 2021-08-14 14:35:44 PDT
Fix static analyzer warnings in WTF for clang tidy bugprone-move-forwarding-reference checker. See: <https://clang.llvm.org/extra/clang-tidy/checks/bugprone-move-forwarding-reference.html> In file included from OpenSource/Source/WTF/wtf/AutomaticThread.cpp:27: In file included from WebKitBuild/usr/local/include/wtf/AutomaticThread.h:29: In file included from WebKitBuild/usr/local/include/wtf/Condition.h:30: In file included from WebKitBuild/usr/local/include/wtf/ParkingLot.h:29: WebKitBuild/usr/local/include/wtf/ScopedLambda.h:128:55: warning: Forwarding reference passed to std::move(), which may unexpectedly cause lvalues to be moved; use std::forward() instead return ScopedLambdaFunctor<FunctionType, Functor>(WTFMove(functor)); ^ In file included from OpenSource/Source/WTF/wtf/AutomaticThread.cpp:26: In file included from OpenSource/Source/WTF/config.h:31: In file included from WebKitBuild/usr/local/include/wtf/FastMalloc.h:26: WebKitBuild/usr/local/include/wtf/StdLibExtras.h:568:24: note: expanded from macro 'WTFMove' #define WTFMove(value) std::move<WTF::CheckMoveParameter>(value) ^
Attachments
Patch v1 (3.27 KB, patch)
2021-08-14 14:46 PDT, David Kilzer (:ddkilzer)
cdumez: review+
David Kilzer (:ddkilzer)
Comment 1 2021-08-14 14:46:37 PDT
Created attachment 435551 [details] Patch v1
EWS
Comment 2 2021-08-19 14:25:21 PDT
Committed r281270 (240695@main): <https://commits.webkit.org/240695@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 435551 [details].
Radar WebKit Bug Importer
Comment 3 2021-08-19 14:26:21 PDT
Note You need to log in before you can comment on or make changes to this bug.