Commit 46b1a52e authored by Georg Neis's avatar Georg Neis Committed by Commit Bot

[turbofan] Make a non-const reference argument const

Bug: v8:9429
Change-Id: I4274206875edd61f36ac51c05d53158b6c1e17fd
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1700072
Auto-Submit: Georg Neis <neis@chromium.org>
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#62701}
parent 52e7020a
......@@ -329,9 +329,7 @@ void StateValuesAccess::iterator::Pop() {
current_depth_--;
}
bool StateValuesAccess::iterator::done() { return current_depth_ < 0; }
bool StateValuesAccess::iterator::done() const { return current_depth_ < 0; }
void StateValuesAccess::iterator::Advance() {
Top()->Advance();
......@@ -392,8 +390,7 @@ MachineType StateValuesAccess::iterator::type() {
}
}
bool StateValuesAccess::iterator::operator!=(
iterator& other) { // NOLINT(runtime/references)
bool StateValuesAccess::iterator::operator!=(iterator const& other) {
// We only allow comparison with end().
CHECK(other.done());
return !done();
......
......@@ -92,7 +92,7 @@ class V8_EXPORT_PRIVATE StateValuesAccess {
class V8_EXPORT_PRIVATE iterator {
public:
// Bare minimum of operators needed for range iteration.
bool operator!=(iterator& other); // NOLINT(runtime/references)
bool operator!=(iterator const& other);
iterator& operator++();
TypedNode operator*();
......@@ -104,7 +104,7 @@ class V8_EXPORT_PRIVATE StateValuesAccess {
Node* node();
MachineType type();
bool done();
bool done() const;
void Advance();
void EnsureValid();
......
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