Commit e9f7bc11 authored by Daniel Cheng's avatar Daniel Cheng Committed by Commit Bot

Match STL naming for WTF::{Deque,HashCountedSet,HashMap,LinkedHashSet,ListHashSet}

Bug: 709815
Change-Id: I8f35864239dc5a606b473cdd82add2e68a76cb08
Reviewed-on: https://chromium-review.googlesource.com/487861Reviewed-by: 's avatarKentaro Hara <haraken@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#467298}
parent 76159880
......@@ -91,8 +91,8 @@ void ScriptWrappableVisitor::PerformCleanup() {
}
headers_to_unmark_.clear();
marking_deque_.Clear();
verifier_deque_.Clear();
marking_deque_.clear();
verifier_deque_.clear();
should_cleanup_ = false;
}
......@@ -146,8 +146,8 @@ void ScriptWrappableVisitor::PerformLazyCleanup(double deadline_seconds) {
// Unmarked all headers.
CHECK(headers_to_unmark_.IsEmpty());
marking_deque_.Clear();
verifier_deque_.Clear();
marking_deque_.clear();
verifier_deque_.clear();
should_cleanup_ = false;
}
......
......@@ -62,7 +62,7 @@ void CSSFontFace::FontLoaded(RemoteFontFaceSource* source) {
SetLoadStatus(FontFace::kLoaded);
} else if (source->GetDisplayPeriod() ==
RemoteFontFaceSource::kFailurePeriod) {
sources_.Clear();
sources_.clear();
SetLoadStatus(FontFace::kError);
} else {
sources_.pop_front();
......
......@@ -81,7 +81,7 @@ void CSSSegmentedFontFace::AddFontFace(FontFace* font_face,
}
void CSSSegmentedFontFace::RemoveFontFace(FontFace* font_face) {
FontFaceList::iterator it = font_faces_.Find(font_face);
FontFaceList::iterator it = font_faces_.find(font_face);
if (it == font_faces_.end())
return;
......
......@@ -298,7 +298,7 @@ bool FontFaceSet::deleteForBinding(ScriptState*,
if (!InActiveDocumentContext())
return false;
HeapListHashSet<Member<FontFace>>::iterator it =
non_css_connected_faces_.Find(font_face);
non_css_connected_faces_.find(font_face);
if (it != non_css_connected_faces_.end()) {
non_css_connected_faces_.erase(it);
CSSFontSelector* font_selector =
......
......@@ -352,7 +352,7 @@ inline Document* Fullscreen::GetDocument() {
}
void Fullscreen::ContextDestroyed(ExecutionContext*) {
event_queue_.Clear();
event_queue_.clear();
if (full_screen_layout_object_)
full_screen_layout_object_->Destroy();
......
......@@ -50,7 +50,7 @@ void UndoStack::RegisterUndoStep(UndoStep* step) {
if (undo_stack_.size() == kMaximumUndoStackDepth)
undo_stack_.pop_front(); // drop oldest item off the far end
if (!in_redo_)
redo_stack_.Clear();
redo_stack_.clear();
undo_stack_.push_back(step);
}
......@@ -90,8 +90,8 @@ void UndoStack::Redo() {
}
void UndoStack::Clear() {
undo_stack_.Clear();
redo_stack_.Clear();
undo_stack_.clear();
redo_stack_.clear();
}
DEFINE_TRACE(UndoStack) {
......
......@@ -183,7 +183,7 @@ void SpellCheckRequester::PrepareForLeakDetection() {
// Rather than somehow wait for this async queue to drain before running
// the leak detector, they're all cancelled to prevent flaky leaks being
// reported.
request_queue_.Clear();
request_queue_.clear();
// WebSpellCheckClient stores a set of WebTextCheckingCompletion objects,
// which may store references to already invoked requests. We should clear
// these references to prevent them from being a leak source.
......@@ -237,7 +237,7 @@ void SpellCheckRequester::DidCheck(int sequence,
DCHECK(processing_request_);
DCHECK_EQ(processing_request_->Data().Sequence(), sequence);
if (processing_request_->Data().Sequence() != sequence) {
request_queue_.Clear();
request_queue_.clear();
return;
}
......
......@@ -99,7 +99,7 @@ bool DOMWindowEventQueue::EnqueueEvent(Event* event) {
}
bool DOMWindowEventQueue::CancelEvent(Event* event) {
HeapListHashSet<Member<Event>, 16>::iterator it = queued_events_.Find(event);
HeapListHashSet<Member<Event>, 16>::iterator it = queued_events_.find(event);
bool found = it != queued_events_.end();
if (found) {
probe::AsyncTaskCanceled(event->target()->GetExecutionContext(), event);
......
......@@ -466,7 +466,7 @@ void HTMLDocumentParser::DiscardSpeculationsAndResumeFrom(
("Parser.DiscardedTokenCount", 1, 100000, 50));
discarded_token_count_histogram.Count(discarded_token_count);
speculations_.Clear();
speculations_.clear();
pending_csp_meta_token_ = nullptr;
queued_preloads_.clear();
......
......@@ -66,7 +66,7 @@ void PointerEventManager::Clear() {
touch_event_manager_->Clear();
in_canceled_state_for_pointer_type_touch_ = false;
pointer_event_factory_.Clear();
touch_ids_for_canceled_pointerdowns_.Clear();
touch_ids_for_canceled_pointerdowns_.clear();
node_under_pointer_.clear();
pointer_capture_target_.clear();
pending_pointer_capture_target_.clear();
......
......@@ -25,7 +25,7 @@ void ConsoleMessageStorage::AddConsoleMessage(ExecutionContext* context,
}
void ConsoleMessageStorage::Clear() {
messages_.Clear();
messages_.clear();
expired_count_ = 0;
}
......
......@@ -381,7 +381,7 @@ void NetworkResourcesData::AddPendingEncodedDataLength(
void NetworkResourcesData::Clear(const String& preserved_loader_id) {
if (!request_id_to_resource_data_map_.size())
return;
request_ids_deque_.Clear();
request_ids_deque_.clear();
content_size_ = 0;
ResourceDataMap preserved_map;
......
......@@ -1060,7 +1060,7 @@ void LayoutBlockFlow::AppendFloatsToLastLine(
FloatingObjectSetIterator end = floating_object_set.end();
if (layout_state.LastFloat()) {
FloatingObjectSetIterator last_float_iterator =
floating_object_set.Find(layout_state.LastFloat());
floating_object_set.find(layout_state.LastFloat());
DCHECK(last_float_iterator != end);
++last_float_iterator;
it = last_float_iterator;
......
......@@ -439,7 +439,7 @@ LayoutUnit LayoutGrid::GuttersSize(const Grid& grid,
size_t non_empty_tracks_after_end_line =
grid.NumTracks(direction) - end_line;
auto current_empty_track =
grid.AutoRepeatEmptyTracks(direction)->Find(end_line - 1);
grid.AutoRepeatEmptyTracks(direction)->find(end_line - 1);
auto end_empty_track = grid.AutoRepeatEmptyTracks(direction)->end();
// HashSet iterators do not implement operator- so we have to manually
// iterate to know the number of remaining empty tracks.
......
......@@ -892,7 +892,7 @@ void LayoutMultiColumnFlowThread::AddColumnSetToThread(
if (LayoutMultiColumnSet* next_set =
column_set->NextSiblingMultiColumnSet()) {
LayoutMultiColumnSetList::iterator it =
multi_column_set_list_.Find(next_set);
multi_column_set_list_.find(next_set);
DCHECK(it != multi_column_set_list_.end());
multi_column_set_list_.InsertBefore(it, column_set);
} else {
......
......@@ -105,7 +105,7 @@ void SMILTimeContainer::Unschedule(SVGSMILElement* animation,
DCHECK_NE(it, scheduled_animations_.end());
AnimationsLinkedHashSet* scheduled = it->value.Get();
DCHECK(scheduled);
AnimationsLinkedHashSet::iterator it_animation = scheduled->Find(animation);
AnimationsLinkedHashSet::iterator it_animation = scheduled->find(animation);
DCHECK(it_animation != scheduled->end());
scheduled->erase(it_animation);
......
......@@ -1034,7 +1034,7 @@ void MediaKeySession::ContextDestroyed(ExecutionContext*) {
session_.reset();
is_closed_ = true;
action_timer_.Stop();
pending_actions_.Clear();
pending_actions_.clear();
async_event_queue_->Close();
}
......
......@@ -302,7 +302,7 @@ DEFINE_TRACE(MediaKeys) {
void MediaKeys::ContextDestroyed(ExecutionContext*) {
timer_.Stop();
pending_actions_.Clear();
pending_actions_.clear();
// We don't need the CDM anymore. Only destroyed after all related
// ContextLifecycleObservers have been stopped.
......
......@@ -228,7 +228,7 @@ class TeeHelper final : public GarbageCollectedFinalized<TeeHelper>,
bool IsEmpty() const { return chunks_.IsEmpty(); }
void ClearChunks() {
chunks_.Clear();
chunks_.clear();
offset_ = 0;
}
......
......@@ -137,14 +137,14 @@ void BytesConsumerTestUtil::ReplayingBytesConsumer::NotifyAsReadable(
}
void BytesConsumerTestUtil::ReplayingBytesConsumer::Close() {
commands_.Clear();
commands_.clear();
offset_ = 0;
state_ = InternalState::kClosed;
++notification_token_;
}
void BytesConsumerTestUtil::ReplayingBytesConsumer::GetError(const Error& e) {
commands_.Clear();
commands_.clear();
offset_ = 0;
error_ = e;
state_ = InternalState::kErrored;
......
......@@ -234,7 +234,7 @@ void NavigatorGamepad::DidRemoveAllEventListeners(LocalDOMWindow*) {
void NavigatorGamepad::DidRemoveGamepadEventListeners() {
has_event_listener_ = false;
dispatch_one_event_runner_->Stop();
pending_events_.Clear();
pending_events_.clear();
}
void NavigatorGamepad::PageVisibilityChanged() {
......
......@@ -521,7 +521,7 @@ void PresentationConnection::TearDown() {
blob_loader_->Cancel();
blob_loader_.Clear();
}
messages_.Clear();
messages_.clear();
}
} // namespace blink
......@@ -107,7 +107,7 @@ void SpeechSynthesis::cancel() {
// Remove all the items from the utterance queue. The platform
// may still have references to some of these utterances and may
// fire events on them asynchronously.
utterance_queue_.Clear();
utterance_queue_.clear();
platform_speech_synthesizer_->Cancel();
}
......
......@@ -117,7 +117,7 @@ void PlatformSpeechSynthesizerMock::Cancel() {
return;
// Per spec, removes all queued utterances.
queued_utterances_.Clear();
queued_utterances_.clear();
speaking_finished_timer_.Stop();
speaking_error_occurred_timer_.StartOneShot(.1, BLINK_FROM_HERE);
......
......@@ -415,7 +415,7 @@ void SQLTransactionBackend::DoCleanup() {
->IsDatabaseThread());
MutexLocker locker(statement_mutex_);
statement_queue_.Clear();
statement_queue_.clear();
if (sqlite_transaction_) {
// In the event we got here because of an interruption or error (i.e. if
......
......@@ -122,7 +122,7 @@ void DOMWebSocket::EventQueue::ContextDestroyed() {
state_ = kStopped;
resume_timer_.Stop();
events_.Clear();
events_.clear();
}
void DOMWebSocket::EventQueue::DispatchQueuedEvents() {
......
......@@ -595,7 +595,7 @@ void HarfBuzzShaper::ShapeSegment(RangeData* range_data,
fallback_chars_hint)) {
// Give up shaping since we cannot retrieve a font fallback
// font without a hintlist.
range_data->holes_queue.Clear();
range_data->holes_queue.clear();
break;
}
......
......@@ -204,7 +204,7 @@ void DrawingBuffer::SetIsHidden(bool hidden) {
return;
is_hidden_ = hidden;
if (is_hidden_)
recycled_color_buffer_queue_.Clear();
recycled_color_buffer_queue_.clear();
}
void DrawingBuffer::SetFilterQuality(SkFilterQuality filter_quality) {
......@@ -800,7 +800,7 @@ void DrawingBuffer::BeginDestruction() {
destruction_in_progress_ = true;
ClearPlatformLayer();
recycled_color_buffer_queue_.Clear();
recycled_color_buffer_queue_.clear();
if (multisample_fbo_)
gl_->DeleteFramebuffers(1, &multisample_fbo_);
......@@ -952,7 +952,7 @@ bool DrawingBuffer::ResizeFramebufferInternal(const IntSize& new_size) {
size_ = adjusted_size;
// Free all mailboxes, because they are now of the wrong size. Only the
// first call in this loop has any effect.
recycled_color_buffer_queue_.Clear();
recycled_color_buffer_queue_.clear();
recycled_bitmaps_.clear();
if (adjusted_size.IsEmpty())
......
......@@ -76,7 +76,7 @@ void SharedContextRateLimiter::Reset() {
queries_.pop_front();
}
} else {
queries_.Clear();
queries_.clear();
}
}
......
......@@ -188,7 +188,7 @@ void TaskQueueImpl::UnregisterTaskQueue() {
any_thread().observer = nullptr;
main_thread_only().observer = nullptr;
main_thread_only().delayed_incoming_queue = std::priority_queue<Task>();
immediate_incoming_queue().Clear();
immediate_incoming_queue().clear();
main_thread_only().immediate_work_queue.reset();
main_thread_only().delayed_work_queue.reset();
}
......
......@@ -48,7 +48,7 @@ void SegmentedString::Clear() {
number_of_characters_consumed_prior_to_current_string_ = 0;
number_of_characters_consumed_prior_to_current_line_ = 0;
current_line_ = 0;
substrings_.Clear();
substrings_.clear();
closed_ = false;
empty_ = true;
fast_path_flags_ = kNoFastPath;
......
......@@ -140,7 +140,7 @@ class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>,
template <typename... Args>
void emplace_front(Args&&...);
void Clear();
void clear();
template <typename VisitorDispatcher>
void Trace(VisitorDispatcher);
......@@ -412,7 +412,7 @@ inline void Deque<T, inlineCapacity, Allocator>::Swap(Deque& other) {
}
template <typename T, size_t inlineCapacity, typename Allocator>
inline void Deque<T, inlineCapacity, Allocator>::Clear() {
inline void Deque<T, inlineCapacity, Allocator>::clear() {
DestroyAll();
start_ = 0;
end_ = 0;
......
......@@ -233,7 +233,7 @@ void OwnPtrTest() {
EXPECT_EQ(count, copy_deque.size());
EXPECT_EQ(0u, deque.size());
copy_deque.Clear();
copy_deque.clear();
EXPECT_EQ(count, static_cast<size_t>(destruct_number));
}
......@@ -402,8 +402,8 @@ void TestDestructorAndConstructorCallsWhenSwappingWithInlineCapacity() {
for (unsigned j = i; j < 12; j++) {
if (!InterestingNumber(j))
continue;
deque.Clear();
deque2.Clear();
deque.clear();
deque2.clear();
EXPECT_EQ(0u, LivenessCounter::live_);
for (unsigned k = 0; k < j; k++)
deque.push_back(&counter);
......@@ -473,8 +473,8 @@ void TestValuesMovedAndSwappedWithInlineCapacity() {
for (unsigned size2 = 0; size2 < 12; size2++) {
if (!InterestingNumber(size2))
continue;
deque.Clear();
deque2.Clear();
deque.clear();
deque2.clear();
for (unsigned i = 0; i < pad; i++)
deque.push_back(103);
for (unsigned i = 0; i < pad2; i++)
......@@ -534,7 +534,7 @@ TEST(DequeTest, UniquePtr) {
ASSERT_EQ(1u, deque.size());
EXPECT_EQ(24, *deque[0]);
deque.Clear();
deque.clear();
}
class CountCopy final {
......
......@@ -66,7 +66,7 @@ class HashCountedSet {
void swap(HashCountedSet& other) { impl_.swap(other.impl_); }
unsigned size() const { return impl_.size(); }
unsigned capacity() const { return impl_.capacity(); }
unsigned Capacity() const { return impl_.capacity(); }
bool IsEmpty() const { return impl_.IsEmpty(); }
// Iterators iterate over pairs of values (called key) and counts (called
......
......@@ -182,7 +182,7 @@ class HashMap {
template <typename HashTranslator,
typename IncomingKeyType,
typename IncomingMappedType>
AddResult insert(IncomingKeyType&&, IncomingMappedType&&);
AddResult Insert(IncomingKeyType&&, IncomingMappedType&&);
static bool IsValidKey(KeyPeekInType);
......@@ -561,7 +561,7 @@ template <typename T,
template <typename HashTranslator,
typename IncomingKeyType,
typename IncomingMappedType>
auto HashMap<T, U, V, W, X, Y>::insert(IncomingKeyType&& key,
auto HashMap<T, U, V, W, X, Y>::Insert(IncomingKeyType&& key,
IncomingMappedType&& mapped)
-> AddResult {
return impl_.template AddPassingHashCode<
......
......@@ -243,8 +243,8 @@ class LinkedHashSet {
const Value& back() const;
void pop_back();
iterator Find(ValuePeekInType);
const_iterator Find(ValuePeekInType) const;
iterator find(ValuePeekInType);
const_iterator find(ValuePeekInType) const;
bool Contains(ValuePeekInType) const;
// An alternate version of find() that finds the object by hashing and
......@@ -735,7 +735,7 @@ inline void LinkedHashSet<T, U, V, W>::pop_back() {
template <typename T, typename U, typename V, typename W>
inline typename LinkedHashSet<T, U, V, W>::iterator
LinkedHashSet<T, U, V, W>::Find(ValuePeekInType value) {
LinkedHashSet<T, U, V, W>::find(ValuePeekInType value) {
LinkedHashSet::Node* node =
impl_.template Lookup<LinkedHashSet::NodeHashFunctions, ValuePeekInType>(
value);
......@@ -746,7 +746,7 @@ LinkedHashSet<T, U, V, W>::Find(ValuePeekInType value) {
template <typename T, typename U, typename V, typename W>
inline typename LinkedHashSet<T, U, V, W>::const_iterator
LinkedHashSet<T, U, V, W>::Find(ValuePeekInType value) const {
LinkedHashSet<T, U, V, W>::find(ValuePeekInType value) const {
const LinkedHashSet::Node* node =
impl_.template Lookup<LinkedHashSet::NodeHashFunctions, ValuePeekInType>(
value);
......@@ -861,7 +861,7 @@ template <typename IncomingValueType>
typename LinkedHashSet<T, U, V, W>::AddResult
LinkedHashSet<T, U, V, W>::InsertBefore(ValuePeekInType before_value,
IncomingValueType&& new_value) {
return InsertBefore(Find(before_value),
return InsertBefore(find(before_value),
std::forward<IncomingValueType>(new_value));
}
......@@ -874,7 +874,7 @@ inline void LinkedHashSet<T, U, V, W>::erase(iterator it) {
template <typename T, typename U, typename V, typename W>
inline void LinkedHashSet<T, U, V, W>::erase(ValuePeekInType value) {
erase(Find(value));
erase(find(value));
}
inline void SwapAnchor(LinkedHashSetNodeBase& a, LinkedHashSetNodeBase& b) {
......
......@@ -173,8 +173,8 @@ class ListHashSet
const ValueType& back() const;
void pop_back();
iterator Find(ValuePeekInType);
const_iterator Find(ValuePeekInType) const;
iterator find(ValuePeekInType);
const_iterator find(ValuePeekInType) const;
bool Contains(ValuePeekInType) const;
// An alternate version of find() that finds the object by hashing and
......@@ -214,7 +214,7 @@ class ListHashSet
template <typename IncomingValueType>
AddResult InsertBefore(iterator, IncomingValueType&&);
void erase(ValuePeekInType value) { return erase(Find(value)); }
void erase(ValuePeekInType value) { return erase(find(value)); }
void erase(iterator);
void clear();
template <typename Collection>
......@@ -850,7 +850,7 @@ inline void ListHashSet<T, inlineCapacity, U, V>::pop_back() {
template <typename T, size_t inlineCapacity, typename U, typename V>
inline typename ListHashSet<T, inlineCapacity, U, V>::iterator
ListHashSet<T, inlineCapacity, U, V>::Find(ValuePeekInType value) {
ListHashSet<T, inlineCapacity, U, V>::find(ValuePeekInType value) {
ImplTypeIterator it = impl_.template Find<BaseTranslator>(value);
if (it == impl_.end())
return end();
......@@ -859,7 +859,7 @@ ListHashSet<T, inlineCapacity, U, V>::Find(ValuePeekInType value) {
template <typename T, size_t inlineCapacity, typename U, typename V>
inline typename ListHashSet<T, inlineCapacity, U, V>::const_iterator
ListHashSet<T, inlineCapacity, U, V>::Find(ValuePeekInType value) const {
ListHashSet<T, inlineCapacity, U, V>::find(ValuePeekInType value) const {
ImplTypeConstIterator it = impl_.template Find<BaseTranslator>(value);
if (it == impl_.end())
return end();
......@@ -990,7 +990,7 @@ ListHashSet<T, inlineCapacity, U, V>::InsertBefore(
ValuePeekInType before_value,
IncomingValueType&& new_value) {
CreateAllocatorIfNeeded();
return InsertBefore(Find(before_value),
return InsertBefore(find(before_value),
std::forward<IncomingValueType>(new_value));
}
......@@ -1025,7 +1025,7 @@ auto ListHashSet<T, inlineCapacity, U, V>::Take(iterator it) -> ValueType {
template <typename T, size_t inlineCapacity, typename U, typename V>
auto ListHashSet<T, inlineCapacity, U, V>::Take(ValuePeekInType value)
-> ValueType {
return Take(Find(value));
return Take(find(value));
}
template <typename T, size_t inlineCapacity, typename U, typename V>
......
......@@ -206,7 +206,7 @@ TYPED_TEST(ListOrLinkedHashSetTest, Find) {
{
const Set& ref = set;
typename Set::const_iterator it = ref.Find(2);
typename Set::const_iterator it = ref.find(2);
EXPECT_EQ(2, *it);
++it;
EXPECT_EQ(3, *it);
......@@ -216,7 +216,7 @@ TYPED_TEST(ListOrLinkedHashSetTest, Find) {
}
{
Set& ref = set;
typename Set::iterator it = ref.Find(2);
typename Set::iterator it = ref.find(2);
EXPECT_EQ(2, *it);
++it;
EXPECT_EQ(3, *it);
......@@ -236,11 +236,11 @@ TYPED_TEST(ListOrLinkedHashSetTest, InsertBefore) {
set.insert(2);
set.insert(3);
typename Set::iterator it = set.Find(2);
typename Set::iterator it = set.find(2);
EXPECT_EQ(2, *it);
set.InsertBefore(it, 1);
if (!can_modify_while_iterating)
it = set.Find(2);
it = set.find(2);
++it;
EXPECT_EQ(3, *it);
EXPECT_EQ(5u, set.size());
......@@ -267,7 +267,7 @@ TYPED_TEST(ListOrLinkedHashSetTest, InsertBefore) {
set.InsertBefore(-1, 103);
EXPECT_EQ(103, set.front());
if (!can_modify_while_iterating)
it = set.Find(1);
it = set.find(1);
++it;
EXPECT_EQ(42, *it);
EXPECT_EQ(7u, set.size());
......@@ -440,9 +440,9 @@ TYPED_TEST(ListOrLinkedHashSetRefPtrTest, ExerciseValuePeekInType) {
typename Set::AddResult add_result = set.insert(ptr);
EXPECT_TRUE(add_result.is_new_entry);
set.Find(ptr);
set.find(ptr);
const Set& const_set(set);
const_set.Find(ptr);
const_set.find(ptr);
EXPECT_TRUE(set.Contains(ptr));
typename Set::iterator it = set.AddReturnIterator(ptr);
set.AppendOrMoveToLast(ptr);
......@@ -559,7 +559,7 @@ TEST(ListHashSetTest, WithOwnPtr) {
EXPECT_FALSE(deleted1);
EXPECT_EQ(1UL, set.size());
OwnPtrSet::iterator it1 = set.Find(ptr1);
OwnPtrSet::iterator it1 = set.find(ptr1);
EXPECT_NE(set.end(), it1);
EXPECT_EQ(ptr1, (*it1).get());
......@@ -571,7 +571,7 @@ TEST(ListHashSetTest, WithOwnPtr) {
EXPECT_FALSE(deleted2);
EXPECT_EQ(2UL, set.size());
OwnPtrSet::iterator it2 = set.Find(ptr2);
OwnPtrSet::iterator it2 = set.find(ptr2);
EXPECT_NE(set.end(), it2);
EXPECT_EQ(ptr2, (*it2).get());
......@@ -768,12 +768,12 @@ TYPED_TEST(ListOrLinkedHashSetMoveOnlyTest, MoveOnlyValue) {
EXPECT_EQ(1, add_result.stored_value->Value());
EXPECT_EQ(1, add_result.stored_value->Id());
}
auto iter = set.Find(MoveOnly(1));
auto iter = set.find(MoveOnly(1));
ASSERT_TRUE(iter != set.end());
EXPECT_EQ(1, iter->Value());
EXPECT_EQ(1, iter->Id());
iter = set.Find(MoveOnly(2));
iter = set.find(MoveOnly(2));
EXPECT_TRUE(iter == set.end());
// ListHashSet and LinkedHashSet have several flavors of add().
......@@ -804,7 +804,7 @@ TYPED_TEST(ListOrLinkedHashSetMoveOnlyTest, MoveOnlyValue) {
EXPECT_EQ(5, add_result.stored_value->Id());
}
{
iter = set.Find(MoveOnly(5));
iter = set.find(MoveOnly(5));
ASSERT_TRUE(iter != set.end());
AddResult add_result = set.InsertBefore(iter, MoveOnly(6, 6));
EXPECT_TRUE(add_result.is_new_entry);
......
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