This is an archive of the discontinued LLVM Phabricator instance.

Add a missing debug assertion in <list>
ClosedPublic

Authored by Quuxplusone on Apr 18 2021, 10:57 AM.

Details

Summary

This came up in D100595.

Diff Detail

Event Timeline

Quuxplusone requested review of this revision.Apr 18 2021, 10:57 AM
Quuxplusone created this revision.
Herald added a reviewer: Restricted Project. · View Herald TranscriptApr 18 2021, 10:57 AM

Just looking for a second libc++ approval at this point.

curdeius accepted this revision.Apr 18 2021, 2:13 PM
curdeius added a subscriber: curdeius.

LGTM if this will get tested by https://reviews.llvm.org/D100595.

libcxx/include/list
2093

Hmm, would it make sense to add as well a debug check that __p is not in range [__f, __l) (that's a UB)?

This revision is now accepted and ready to land.Apr 18 2021, 2:13 PM
libcxx/include/list
2093

Perhaps, but I don't think we have any such assertions at the moment, and that would need a new test; so I'm deferring it to a separate PR (and probably a separate programmer :))

This revision was automatically updated to reflect the committed changes.