llvm-project
219511ae - [APINotes] Make an assert in a std::sort call tolerate self-comparisons

Commit
1 year ago
[APINotes] Make an assert in a std::sort call tolerate self-comparisons libc++ debug mode verifies that a comparator passed to std::sort defines a strict weak order by calling it with the same element. See also: - RFC that introduced the feature: https://discourse.llvm.org/t/rfc-strict-weak-ordering-checks-in-the-debug-libc/70217 - `strict_weak_ordering_check.h` in libc++ sources.
Author
Committer
Parents
Loading