Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore: attempted fix for compiler error
  • Loading branch information
bcoe committed Mar 11, 2019
commit de7ffec2fcd808e9cbcd78c2f6f34e510c5fb00c
8 changes: 0 additions & 8 deletions deps/v8/src/zone/zone-list-inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -128,14 +128,6 @@ void ZoneList<T>::Iterate(Visitor* visitor) {
for (int i = 0; i < length_; i++) visitor->Apply(&data_[i]);
}

template <typename T>
bool ZoneList<T>::Contains(const T& elm) const {
for (int i = 0; i < length_; i++) {
if (data_[i] == elm) return true;
}
return false;
}

template <typename T>
template <typename CompareFunction>
void ZoneList<T>::Sort(CompareFunction cmp) {
Expand Down
7 changes: 6 additions & 1 deletion deps/v8/src/zone/zone.h
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,12 @@ class ZoneList final {
// Drops all but the first 'pos' elements from the list.
INLINE(void Rewind(int pos));

inline bool Contains(const T& elm) const;
inline bool Contains(const T& elm) const {
for (int i = 0; i < length_; i++) {
if (data_[i] == elm) return true;
}
return false;
}

// Iterate through all list entries, starting at index 0.
template <class Visitor>
Expand Down