RESOLVED FIXED 192707
clang-tidy: Fix unnecessary object copy in CPUMonitor::setCPULimit()
https://bugs.webkit.org/show_bug.cgi?id=192707
Summary clang-tidy: Fix unnecessary object copy in CPUMonitor::setCPULimit()
David Kilzer (:ddkilzer)
Reported 2018-12-14 10:49:55 PST
Running `clang-tidy -checks='-*,performance-*,-performance-noexcept-*' ...` on WebCore source files found this unnecessary object copy: Source/WebCore/platform/CPUMonitor.cpp:38:52: warning: the parameter 'cpuLimit' is copied for each invocation but only used as a const reference; consider making it a const reference [performance-unnecessary-value-param] void CPUMonitor::setCPULimit(std::optional<double> cpuLimit) ^ const &
Attachments
Patch v1 (3.61 KB, patch)
2018-12-14 10:56 PST, David Kilzer (:ddkilzer)
no flags
Radar WebKit Bug Importer
Comment 1 2018-12-14 10:50:43 PST
David Kilzer (:ddkilzer)
Comment 2 2018-12-14 10:56:24 PST
Created attachment 357323 [details] Patch v1
WebKit Commit Bot
Comment 3 2018-12-17 20:09:59 PST
Comment on attachment 357323 [details] Patch v1 Clearing flags on attachment: 357323 Committed r239315: <https://trac.webkit.org/changeset/239315>
WebKit Commit Bot
Comment 4 2018-12-17 20:10:00 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.