]> git.ipfire.org Git - thirdparty/gcc.git/commit
libstdc++: Simplify constraints on <=> for std::reference_wrapper
authorJonathan Wakely <jwakely@redhat.com>
Fri, 19 Apr 2024 16:42:04 +0000 (17:42 +0100)
committerJonathan Wakely <jwakely@redhat.com>
Fri, 19 Apr 2024 20:06:29 +0000 (21:06 +0100)
commitd86472a6f041ccf3d1be0cf6bb15d1e0ad8f6dbe
treeb5f7e34cc51e995143a6499e72d83f35d523803c
parenteed7fb1b2fe72150cd6af10dd3b8f7fc4f0a4da1
libstdc++: Simplify constraints on <=> for std::reference_wrapper

Instead of constraining these overloads in terms of synth-three-way we
can just check that the value_type is less-than-comparable, which is
what synth-three-way's constraints check.

The reason that I implemented these with constraints has now been filed
as LWG 4071, so add a comment about that too.

libstdc++-v3/ChangeLog:

* include/bits/refwrap.h (operator<=>): Simplify constraints.
libstdc++-v3/include/bits/refwrap.h