sorted_vector_types: improve compatibility with maps whose reference isn't `const...
commit003ac67812f8857a265865f68fa8f2f392b3449f
authorScott Wolchok <swolchok@meta.com>
Fri, 14 Oct 2022 20:13:08 +0000 (14 13:13 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Fri, 14 Oct 2022 20:13:08 +0000 (14 13:13 -0700)
treec51caa4698643167ed52ad6b53ed0fd74a303187
parent049cde00d57aaff9bd044a2cc2146bdb51b5d055
sorted_vector_types: improve compatibility with maps whose reference isn't `const value_type&`

Summary: I have an in-progress fancy map that works like the upcoming `std::flat_map`, where `reference` is actually a pair-of-references type. Converting to `const value_type&` here was forcing a copy of the map entry. `const auto&` works the same for normal code while not causing problems with fancy stuff either.

Reviewed By: Gownta

Differential Revision: D40209620

fbshipit-source-id: 3b0350f5ef2fab1469225c45dfdc73bd7865977a
third-party/folly/src/folly/sorted_vector_types.h