This is an archive of the discontinued LLVM Phabricator instance.

[libc++] [LIBCXX-DEBUG-FIXME] Stop using invalid iterators to insert into sets/maps.
ClosedPublic

Authored by Quuxplusone on Apr 30 2021, 5:01 PM.

Details

Summary
This simply applies Howard's commit 4c80bfbd53caf consistently
across all the associative and unordered container tests.

"unord.set/insert_hint_const_lvalue.pass.cpp" failed with `-D_LIBCPP_DEBUG=1`
before this patch; it was the only one that incorrectly reused
invalid iterator `e`. The others already used valid iterators
(generally `c.end()`); I'm just making them all match the same pattern
of usage: "e, then r, then c.end() for the rest."

Diff Detail

Event Timeline

Quuxplusone requested review of this revision.Apr 30 2021, 5:01 PM
Quuxplusone created this revision.
Herald added 1 blocking reviewer(s): Restricted Project. · View Herald TranscriptApr 30 2021, 5:01 PM

rebase to poke buildkite

ldionne accepted this revision.May 5 2021, 10:59 AM
This revision is now accepted and ready to land.May 5 2021, 10:59 AM