Commit 1f237492 authored by Clemens Hammacher's avatar Clemens Hammacher Committed by Commit Bot

[base] Remove non-const reference

This fixes the only violation of the 'runtime/references' warning in
src/base by using a forwarding reference.

R=mlippautz@chromium.org

Bug: v8:9429, v8:9396
Change-Id: Ide2d28ab647e1cec78979c3f6d664b53c92a7d6e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1690839
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#62564}
parent 9efaf554
......@@ -45,7 +45,7 @@ class ReversedAdapter {
// // iterates through v from back to front
// }
template <typename T>
ReversedAdapter<T> Reversed(T& t) { // NOLINT(runtime/references)
ReversedAdapter<T> Reversed(T&& t) {
return ReversedAdapter<T>(t);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment