Skip to content

Commit 30ccfb2

Browse files
Milad FarazmandCommit Bot
authored andcommitted
[turbofan] Overload the -- operator under the LookupReturn Iterator
Changes introduced in 30ec6a8 generates compilation error in gcc 8.1.0: 8.1.0/include/c++/bits/stl_iterator_base_funcs.h:183:2: error: no match for 'operator--' (operand type is 'v8::internal::HandlerTable::LookupReturn(int)::Iterator') --__i; Which maybe caused by the following change in stl_iterator_base_funcs: https://gcc.gnu.org/viewcvs/gcc?view=revision&revision=248875 Overloading the "--" operator fixes the compilation error. Change-Id: I32f54ddd4993375bf905996b5b1e66cd005256da Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1888190 Commit-Queue: Milad Farazmand <miladfar@ca.ibm.com> Commit-Queue: Clemens Backes <clemensb@chromium.org> Reviewed-by: Clemens Backes <clemensb@chromium.org> Cr-Commit-Position: refs/heads/master@{#64624}
1 parent 9cbc125 commit 30ccfb2

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/codegen/handler-table.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,10 @@ int HandlerTable::LookupReturn(int pc_offset) {
203203
index++;
204204
return *this;
205205
}
206+
Iterator& operator--() {
207+
index--;
208+
return *this;
209+
}
206210
Iterator& operator+=(difference_type offset) {
207211
index += offset;
208212
return *this;

0 commit comments

Comments
 (0)