aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2020-11-05 18:36:19 +0000
committerJonathan Wakely <jwakely@redhat.com>2020-11-05 19:09:22 +0000
commitcdd2d448d8200ed5ebcb232163954367b553291e (patch)
tree513dc26b087c5b85ce1b2d58c07134bb11cb911a /gcc
parent10508db867934264bbc2578f1f454c19fa558fd3 (diff)
downloadgcc-cdd2d448d8200ed5ebcb232163954367b553291e.zip
gcc-cdd2d448d8200ed5ebcb232163954367b553291e.tar.gz
gcc-cdd2d448d8200ed5ebcb232163954367b553291e.tar.bz2
libstdc++: Fix constraints on std::optional comparisons [PR 96269]
The relational operators for std::optional were using the wrong types in the declval expressions used to constrain them. Instead of using const lvalues they were using non-const rvalues, which meant that a type might satisfy the constraints but then give an error when the function body was instantiated. libstdc++-v3/ChangeLog: PR libstdc++/96269 * include/std/optional (operator==, operator!=, operator<) (operator>, operator<=, operator>=): Fix types used in SFINAE constraints. * testsuite/20_util/optional/relops/96269.cc: New test.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions