7b1de3eb9e
As explained in the PR, the grammar in the Concepts TS means that a [ token following a requires-clause is parsed as part of the logical-or-expression rather than the start of an attribute. That makes the following ill-formed when using -fconcepts-ts: template<typename T> requires foo<T> [[nodiscard]] int f(T); This change moves all attributes that follow a requires-clause to the end of the function declarator. Signed-off-by: Jonathan Wakely <jwakely@redhat.com> libstdc++-v3/ChangeLog: PR libstdc++/101782 * include/bits/ranges_base.h (ranges::begin, ranges::end) (ranges::rbegin, ranges::rend, ranges::size, ranges::ssize) (ranges::empty, ranges::data): Move attribute to the end of the declarator. * include/bits/stl_iterator.h (__gnu_cxx::__normal_iterator) (common_iterator): Likewise for non-member operator functions. * include/std/ranges (views::all, views::filter) (views::transform, views::take, views::take_while, views::drop) (views::drop_while, views::join, views::lazy_split) (views::split, views::counted, views::common, views::reverse) (views::elements): Likewise. * testsuite/std/ranges/access/101782.cc: New test. |
||
---|---|---|
.. | ||
backward | ||
bits | ||
c | ||
c_compatibility | ||
c_global | ||
c_std | ||
debug | ||
decimal | ||
experimental | ||
ext | ||
parallel | ||
precompiled | ||
pstl | ||
std | ||
tr1 | ||
tr2 | ||
Makefile.am | ||
Makefile.in |