This is an archive of the discontinued LLVM Phabricator instance.

Use const predicate operators in algorithms
Needs ReviewPublic

Authored by zoecarver on Apr 17 2019, 8:23 PM.

Details

Reviewers
mclow.lists
Summary

This patch ensures that algorithms in libc++ use const overloads for predicate operators. It also adds a file called test_predicates.h which holds helpful testing predicates. See bug 34536 and LWG3031 for reference.

Diff Detail

Event Timeline

zoecarver created this revision.Apr 17 2019, 8:23 PM
zoecarver edited the summary of this revision. (Show Details)Apr 17 2019, 8:24 PM
jloser added a subscriber: jloser.Apr 18 2019, 6:50 PM
jloser added inline comments.
test/support/test_predicates.h
2

Nit: typo -- should be stateful.

zoecarver updated this revision to Diff 195856.Apr 18 2019, 9:07 PM
zoecarver marked an inline comment as done.

Fix typo

Ping. I can split this into three patches if that would be better.