- tmp/tmpbqnpi0hl/{from.md → to.md} +208 -148
tmp/tmpbqnpi0hl/{from.md → to.md}
RENAMED
|
@@ -13,359 +13,405 @@ namespace std {
|
|
| 13 |
{ *t } -> can-reference; // not required to be equality-preserving
|
| 14 |
};
|
| 15 |
|
| 16 |
// [iterator.assoc.types], associated types
|
| 17 |
// [incrementable.traits], incrementable traits
|
| 18 |
-
template<class> struct incrementable_traits;
|
| 19 |
template<class T>
|
| 20 |
-
using iter_difference_t = see below;
|
| 21 |
|
| 22 |
// [readable.traits], indirectly readable traits
|
| 23 |
-
template<class> struct indirectly_readable_traits;
|
| 24 |
template<class T>
|
| 25 |
-
using iter_value_t = see below;
|
| 26 |
|
| 27 |
// [iterator.traits], iterator traits
|
| 28 |
-
template<class I> struct iterator_traits;
|
| 29 |
-
template<class T> requires is_object_v<T> struct iterator_traits<T*>;
|
| 30 |
|
| 31 |
template<dereferenceable T>
|
| 32 |
-
using iter_reference_t = decltype(*declval<T&>());
|
| 33 |
|
| 34 |
namespace ranges {
|
| 35 |
-
// [iterator.cust], customization
|
| 36 |
inline namespace unspecified {
|
| 37 |
// [iterator.cust.move], ranges::iter_move
|
| 38 |
-
inline constexpr unspecified iter_move = unspecified;
|
| 39 |
|
| 40 |
// [iterator.cust.swap], ranges::iter_swap
|
| 41 |
-
inline constexpr unspecified iter_swap = unspecified;
|
| 42 |
}
|
| 43 |
}
|
| 44 |
|
| 45 |
template<dereferenceable T>
|
| 46 |
requires requires(T& t) {
|
| 47 |
{ ranges::iter_move(t) } -> can-reference;
|
| 48 |
}
|
| 49 |
-
using iter_rvalue_reference_t
|
| 50 |
= decltype(ranges::iter_move(declval<T&>()));
|
| 51 |
|
| 52 |
// [iterator.concepts], iterator concepts
|
| 53 |
// [iterator.concept.readable], concept indirectly_readable
|
| 54 |
template<class In>
|
| 55 |
-
concept indirectly_readable = see below;
|
| 56 |
|
| 57 |
template<indirectly_readable T>
|
| 58 |
-
using
|
| 59 |
-
|
|
|
|
|
|
|
|
|
|
| 60 |
|
| 61 |
// [iterator.concept.writable], concept indirectly_writable
|
| 62 |
template<class Out, class T>
|
| 63 |
-
concept indirectly_writable = see below;
|
| 64 |
|
| 65 |
// [iterator.concept.winc], concept weakly_incrementable
|
| 66 |
template<class I>
|
| 67 |
-
concept weakly_incrementable = see below;
|
| 68 |
|
| 69 |
// [iterator.concept.inc], concept incrementable
|
| 70 |
template<class I>
|
| 71 |
-
concept incrementable = see below;
|
| 72 |
|
| 73 |
// [iterator.concept.iterator], concept input_or_output_iterator
|
| 74 |
template<class I>
|
| 75 |
-
concept input_or_output_iterator = see below;
|
| 76 |
|
| 77 |
// [iterator.concept.sentinel], concept sentinel_for
|
| 78 |
template<class S, class I>
|
| 79 |
-
concept sentinel_for = see below;
|
| 80 |
|
| 81 |
// [iterator.concept.sizedsentinel], concept sized_sentinel_for
|
| 82 |
template<class S, class I>
|
| 83 |
-
|
| 84 |
|
| 85 |
template<class S, class I>
|
| 86 |
-
concept sized_sentinel_for = see below;
|
| 87 |
|
| 88 |
// [iterator.concept.input], concept input_iterator
|
| 89 |
template<class I>
|
| 90 |
-
concept input_iterator = see below;
|
| 91 |
|
| 92 |
// [iterator.concept.output], concept output_iterator
|
| 93 |
template<class I, class T>
|
| 94 |
-
concept output_iterator = see below;
|
| 95 |
|
| 96 |
// [iterator.concept.forward], concept forward_iterator
|
| 97 |
template<class I>
|
| 98 |
-
concept forward_iterator = see below;
|
| 99 |
|
| 100 |
// [iterator.concept.bidir], concept bidirectional_iterator
|
| 101 |
template<class I>
|
| 102 |
-
concept bidirectional_iterator = see below;
|
| 103 |
|
| 104 |
// [iterator.concept.random.access], concept random_access_iterator
|
| 105 |
template<class I>
|
| 106 |
-
concept random_access_iterator = see below;
|
| 107 |
|
| 108 |
// [iterator.concept.contiguous], concept contiguous_iterator
|
| 109 |
template<class I>
|
| 110 |
-
concept contiguous_iterator = see below;
|
| 111 |
|
| 112 |
// [indirectcallable], indirect callable requirements
|
| 113 |
// [indirectcallable.indirectinvocable], indirect callables
|
| 114 |
template<class F, class I>
|
| 115 |
-
concept indirectly_unary_invocable = see below;
|
| 116 |
|
| 117 |
template<class F, class I>
|
| 118 |
-
concept indirectly_regular_unary_invocable = see below;
|
| 119 |
|
| 120 |
template<class F, class I>
|
| 121 |
-
concept indirect_unary_predicate = see below;
|
| 122 |
|
| 123 |
template<class F, class I1, class I2>
|
| 124 |
-
concept indirect_binary_predicate = see below;
|
| 125 |
|
| 126 |
template<class F, class I1, class I2 = I1>
|
| 127 |
-
concept indirect_equivalence_relation = see below;
|
| 128 |
|
| 129 |
template<class F, class I1, class I2 = I1>
|
| 130 |
-
concept indirect_strict_weak_order = see below;
|
| 131 |
|
| 132 |
template<class F, class... Is>
|
| 133 |
requires (indirectly_readable<Is> && ...) && invocable<F, iter_reference_t<Is>...>
|
| 134 |
-
using indirect_result_t = invoke_result_t<F, iter_reference_t<Is>...>;
|
| 135 |
|
| 136 |
// [projected], projected
|
| 137 |
template<indirectly_readable I, indirectly_regular_unary_invocable<I> Proj>
|
| 138 |
-
struct projected;
|
| 139 |
|
| 140 |
template<weakly_incrementable I, class Proj>
|
| 141 |
-
struct incrementable_traits<projected<I, Proj>>;
|
| 142 |
|
| 143 |
// [alg.req], common algorithm requirements
|
| 144 |
// [alg.req.ind.move], concept indirectly_movable
|
| 145 |
template<class In, class Out>
|
| 146 |
-
concept indirectly_movable = see below;
|
| 147 |
|
| 148 |
template<class In, class Out>
|
| 149 |
-
concept indirectly_movable_storable = see below;
|
| 150 |
|
| 151 |
// [alg.req.ind.copy], concept indirectly_copyable
|
| 152 |
template<class In, class Out>
|
| 153 |
-
concept indirectly_copyable = see below;
|
| 154 |
|
| 155 |
template<class In, class Out>
|
| 156 |
-
concept indirectly_copyable_storable = see below;
|
| 157 |
|
| 158 |
// [alg.req.ind.swap], concept indirectly_swappable
|
| 159 |
template<class I1, class I2 = I1>
|
| 160 |
-
concept indirectly_swappable = see below;
|
| 161 |
|
| 162 |
// [alg.req.ind.cmp], concept indirectly_comparable
|
| 163 |
template<class I1, class I2, class R, class P1 = identity, class P2 = identity>
|
| 164 |
-
concept indirectly_comparable = see below;
|
| 165 |
|
| 166 |
// [alg.req.permutable], concept permutable
|
| 167 |
template<class I>
|
| 168 |
-
concept permutable = see below;
|
| 169 |
|
| 170 |
// [alg.req.mergeable], concept mergeable
|
| 171 |
template<class I1, class I2, class Out,
|
| 172 |
class R = ranges::less, class P1 = identity, class P2 = identity>
|
| 173 |
-
concept mergeable = see below;
|
| 174 |
|
| 175 |
// [alg.req.sortable], concept sortable
|
| 176 |
template<class I, class R = ranges::less, class P = identity>
|
| 177 |
-
concept sortable = see below;
|
| 178 |
|
| 179 |
// [iterator.primitives], primitives
|
| 180 |
// [std.iterator.tags], iterator tags
|
| 181 |
-
struct input_iterator_tag { };
|
| 182 |
-
struct output_iterator_tag { };
|
| 183 |
-
struct forward_iterator_tag: public input_iterator_tag { };
|
| 184 |
-
struct bidirectional_iterator_tag: public forward_iterator_tag { };
|
| 185 |
-
struct random_access_iterator_tag: public bidirectional_iterator_tag { };
|
| 186 |
-
struct contiguous_iterator_tag: public random_access_iterator_tag { };
|
| 187 |
|
| 188 |
// [iterator.operations], iterator operations
|
| 189 |
template<class InputIterator, class Distance>
|
| 190 |
constexpr void
|
| 191 |
-
advance(InputIterator& i, Distance n);
|
| 192 |
template<class InputIterator>
|
| 193 |
constexpr typename iterator_traits<InputIterator>::difference_type
|
| 194 |
-
distance(InputIterator first, InputIterator last);
|
| 195 |
template<class InputIterator>
|
| 196 |
constexpr InputIterator
|
| 197 |
-
next(InputIterator x,
|
| 198 |
typename iterator_traits<InputIterator>::difference_type n = 1);
|
| 199 |
template<class BidirectionalIterator>
|
| 200 |
constexpr BidirectionalIterator
|
| 201 |
-
prev(BidirectionalIterator x,
|
| 202 |
typename iterator_traits<BidirectionalIterator>::difference_type n = 1);
|
| 203 |
|
| 204 |
// [range.iter.ops], range iterator operations
|
| 205 |
namespace ranges {
|
| 206 |
// [range.iter.op.advance], ranges::advance
|
| 207 |
template<input_or_output_iterator I>
|
| 208 |
-
constexpr void advance(I& i, iter_difference_t<I> n);
|
| 209 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 210 |
-
constexpr void advance(I& i, S bound);
|
| 211 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 212 |
-
constexpr iter_difference_t<I> advance(I& i, iter_difference_t<I> n,
|
|
|
|
| 213 |
|
| 214 |
// [range.iter.op.distance], ranges::distance
|
| 215 |
-
template<
|
| 216 |
-
|
|
|
|
|
|
|
|
|
|
| 217 |
template<range R>
|
| 218 |
-
constexpr range_difference_t<R> distance(R&& r);
|
| 219 |
|
| 220 |
// [range.iter.op.next], ranges::next
|
| 221 |
template<input_or_output_iterator I>
|
| 222 |
-
constexpr I next(I x);
|
| 223 |
template<input_or_output_iterator I>
|
| 224 |
-
constexpr I next(I x, iter_difference_t<I> n);
|
| 225 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 226 |
-
constexpr I next(I x, S bound);
|
| 227 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 228 |
-
constexpr I next(I x, iter_difference_t<I> n, S bound);
|
| 229 |
|
| 230 |
// [range.iter.op.prev], ranges::prev
|
| 231 |
template<bidirectional_iterator I>
|
| 232 |
-
constexpr I prev(I x);
|
| 233 |
template<bidirectional_iterator I>
|
| 234 |
-
constexpr I prev(I x, iter_difference_t<I> n);
|
| 235 |
template<bidirectional_iterator I>
|
| 236 |
-
constexpr I prev(I x, iter_difference_t<I> n, I bound);
|
| 237 |
}
|
| 238 |
|
| 239 |
// [predef.iterators], predefined iterators and sentinels
|
| 240 |
// [reverse.iterators], reverse iterators
|
| 241 |
-
template<class Iterator> class reverse_iterator;
|
| 242 |
|
| 243 |
template<class Iterator1, class Iterator2>
|
| 244 |
-
constexpr bool operator==(
|
| 245 |
const reverse_iterator<Iterator1>& x,
|
| 246 |
const reverse_iterator<Iterator2>& y);
|
| 247 |
template<class Iterator1, class Iterator2>
|
| 248 |
-
constexpr bool operator!=(
|
| 249 |
const reverse_iterator<Iterator1>& x,
|
| 250 |
const reverse_iterator<Iterator2>& y);
|
| 251 |
template<class Iterator1, class Iterator2>
|
| 252 |
-
constexpr bool operator<(
|
| 253 |
const reverse_iterator<Iterator1>& x,
|
| 254 |
const reverse_iterator<Iterator2>& y);
|
| 255 |
template<class Iterator1, class Iterator2>
|
| 256 |
-
constexpr bool operator>(
|
| 257 |
const reverse_iterator<Iterator1>& x,
|
| 258 |
const reverse_iterator<Iterator2>& y);
|
| 259 |
template<class Iterator1, class Iterator2>
|
| 260 |
-
constexpr bool operator<=(
|
| 261 |
const reverse_iterator<Iterator1>& x,
|
| 262 |
const reverse_iterator<Iterator2>& y);
|
| 263 |
template<class Iterator1, class Iterator2>
|
| 264 |
-
constexpr bool operator>=(
|
| 265 |
const reverse_iterator<Iterator1>& x,
|
| 266 |
const reverse_iterator<Iterator2>& y);
|
| 267 |
template<class Iterator1, three_way_comparable_with<Iterator1> Iterator2>
|
| 268 |
constexpr compare_three_way_result_t<Iterator1, Iterator2>
|
| 269 |
-
operator<=>(const reverse_iterator<Iterator1>& x,
|
| 270 |
const reverse_iterator<Iterator2>& y);
|
| 271 |
|
| 272 |
template<class Iterator1, class Iterator2>
|
| 273 |
-
constexpr auto operator-(
|
| 274 |
const reverse_iterator<Iterator1>& x,
|
| 275 |
const reverse_iterator<Iterator2>& y) -> decltype(y.base() - x.base());
|
| 276 |
template<class Iterator>
|
| 277 |
-
constexpr reverse_iterator<Iterator>
|
| 278 |
-
|
| 279 |
-
typename reverse_iterator<Iterator>::difference_type n,
|
| 280 |
const reverse_iterator<Iterator>& x);
|
| 281 |
|
| 282 |
template<class Iterator>
|
| 283 |
-
constexpr reverse_iterator<Iterator> make_reverse_iterator(Iterator i);
|
| 284 |
|
| 285 |
template<class Iterator1, class Iterator2>
|
| 286 |
requires (!sized_sentinel_for<Iterator1, Iterator2>)
|
| 287 |
-
|
| 288 |
reverse_iterator<Iterator2>> = true;
|
| 289 |
|
| 290 |
// [insert.iterators], insert iterators
|
| 291 |
-
template<class Container> class back_insert_iterator;
|
| 292 |
template<class Container>
|
| 293 |
-
constexpr back_insert_iterator<Container> back_inserter(Container& x);
|
| 294 |
|
| 295 |
-
template<class Container> class front_insert_iterator;
|
| 296 |
template<class Container>
|
| 297 |
-
constexpr front_insert_iterator<Container> front_inserter(Container& x);
|
| 298 |
|
| 299 |
-
template<class Container> class insert_iterator;
|
| 300 |
template<class Container>
|
| 301 |
constexpr insert_iterator<Container>
|
| 302 |
-
inserter(Container& x, ranges::iterator_t<Container> i);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 303 |
|
| 304 |
// [move.iterators], move iterators and sentinels
|
| 305 |
-
template<class Iterator> class move_iterator;
|
| 306 |
|
| 307 |
template<class Iterator1, class Iterator2>
|
| 308 |
-
constexpr bool operator==(
|
| 309 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 310 |
template<class Iterator1, class Iterator2>
|
| 311 |
-
constexpr bool operator<(
|
| 312 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 313 |
template<class Iterator1, class Iterator2>
|
| 314 |
-
constexpr bool operator>(
|
| 315 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 316 |
template<class Iterator1, class Iterator2>
|
| 317 |
-
constexpr bool operator<=(
|
| 318 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 319 |
template<class Iterator1, class Iterator2>
|
| 320 |
-
constexpr bool operator>=(
|
| 321 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 322 |
template<class Iterator1, three_way_comparable_with<Iterator1> Iterator2>
|
| 323 |
constexpr compare_three_way_result_t<Iterator1, Iterator2>
|
| 324 |
-
operator<=>(const move_iterator<Iterator1>& x,
|
| 325 |
const move_iterator<Iterator2>& y);
|
| 326 |
|
| 327 |
template<class Iterator1, class Iterator2>
|
| 328 |
-
constexpr auto operator-(
|
| 329 |
-
|
| 330 |
-
|
| 331 |
template<class Iterator>
|
| 332 |
-
constexpr move_iterator<Iterator>
|
| 333 |
-
|
| 334 |
|
| 335 |
template<class Iterator>
|
| 336 |
-
constexpr move_iterator<Iterator> make_move_iterator(Iterator i);
|
| 337 |
|
| 338 |
-
template<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 339 |
|
| 340 |
// [iterators.common], common iterators
|
| 341 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 342 |
requires (!same_as<I, S> && copyable<I>)
|
| 343 |
-
class common_iterator;
|
| 344 |
|
| 345 |
template<class I, class S>
|
| 346 |
-
struct incrementable_traits<common_iterator<I, S>>;
|
| 347 |
|
| 348 |
template<input_iterator I, class S>
|
| 349 |
-
struct iterator_traits<common_iterator<I, S>>;
|
| 350 |
|
| 351 |
-
// [default.
|
| 352 |
-
struct default_sentinel_t;
|
| 353 |
-
inline constexpr default_sentinel_t default_sentinel{};
|
| 354 |
|
| 355 |
// [iterators.counted], counted iterators
|
| 356 |
-
template<input_or_output_iterator I> class counted_iterator;
|
| 357 |
-
|
| 358 |
-
template<class I>
|
| 359 |
-
struct incrementable_traits<counted_iterator<I>>;
|
| 360 |
|
| 361 |
template<input_iterator I>
|
| 362 |
-
|
|
|
|
| 363 |
|
| 364 |
-
// [unreachable.
|
| 365 |
-
struct unreachable_sentinel_t;
|
| 366 |
-
inline constexpr unreachable_sentinel_t unreachable_sentinel{};
|
| 367 |
|
| 368 |
// [stream.iterators], stream iterators
|
| 369 |
template<class T, class charT = char, class traits = char_traits<charT>,
|
| 370 |
class Distance = ptrdiff_t>
|
| 371 |
class istream_iterator;
|
|
@@ -384,41 +430,55 @@ namespace std {
|
|
| 384 |
|
| 385 |
template<class charT, class traits = char_traits<charT>>
|
| 386 |
class ostreambuf_iterator;
|
| 387 |
|
| 388 |
// [iterator.range], range access
|
| 389 |
-
template<class C> constexpr auto begin(C& c) -> decltype(c.begin());
|
| 390 |
-
template<class C> constexpr auto begin(const C& c) -> decltype(c.begin());
|
| 391 |
-
template<class C> constexpr auto end(C& c) -> decltype(c.end());
|
| 392 |
-
template<class C> constexpr auto end(const C& c) -> decltype(c.end());
|
| 393 |
-
template<class T, size_t N> constexpr T* begin(T (&array)[N]) noexcept;
|
| 394 |
-
template<class T, size_t N> constexpr T* end(T (&array)[N]) noexcept;
|
| 395 |
-
template<class C> constexpr auto cbegin(const C& c)
|
| 396 |
-
-> decltype(std::begin(c));
|
| 397 |
-
template<class C> constexpr auto cend(const C& c)
|
| 398 |
-
-> decltype(std::end(c));
|
| 399 |
-
template<class C> constexpr auto rbegin(C& c) -> decltype(c.rbegin());
|
| 400 |
-
template<class C> constexpr auto rbegin(const C& c) -> decltype(c.rbegin());
|
| 401 |
-
template<class C> constexpr auto rend(C& c) -> decltype(c.rend());
|
| 402 |
-
template<class C> constexpr auto rend(const C& c) -> decltype(c.rend());
|
| 403 |
-
template<class T, size_t N> constexpr reverse_iterator<T*> rbegin(T (&array)[N])
|
| 404 |
-
template<class T, size_t N> constexpr reverse_iterator<T*> rend(T (&array)[N]);
|
| 405 |
-
template<class E> constexpr reverse_iterator<const E*>
|
| 406 |
-
|
| 407 |
-
template<class
|
| 408 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 409 |
|
| 410 |
-
template<class C> constexpr auto
|
| 411 |
-
|
| 412 |
-
template<class
|
| 413 |
-
|
| 414 |
-
|
| 415 |
-
template<class C>
|
| 416 |
-
|
| 417 |
-
|
| 418 |
-
template<class
|
| 419 |
-
|
| 420 |
-
|
| 421 |
-
template<class
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 422 |
}
|
| 423 |
```
|
| 424 |
|
|
|
|
| 13 |
{ *t } -> can-reference; // not required to be equality-preserving
|
| 14 |
};
|
| 15 |
|
| 16 |
// [iterator.assoc.types], associated types
|
| 17 |
// [incrementable.traits], incrementable traits
|
| 18 |
+
template<class> struct incrementable_traits; // freestanding
|
| 19 |
template<class T>
|
| 20 |
+
using iter_difference_t = see below; // freestanding
|
| 21 |
|
| 22 |
// [readable.traits], indirectly readable traits
|
| 23 |
+
template<class> struct indirectly_readable_traits; // freestanding
|
| 24 |
template<class T>
|
| 25 |
+
using iter_value_t = see below; // freestanding
|
| 26 |
|
| 27 |
// [iterator.traits], iterator traits
|
| 28 |
+
template<class I> struct iterator_traits; // freestanding
|
| 29 |
+
template<class T> requires is_object_v<T> struct iterator_traits<T*>; // freestanding
|
| 30 |
|
| 31 |
template<dereferenceable T>
|
| 32 |
+
using iter_reference_t = decltype(*declval<T&>()); // freestanding
|
| 33 |
|
| 34 |
namespace ranges {
|
| 35 |
+
// [iterator.cust], customization point objects
|
| 36 |
inline namespace unspecified {
|
| 37 |
// [iterator.cust.move], ranges::iter_move
|
| 38 |
+
inline constexpr unspecified iter_move = unspecified; // freestanding
|
| 39 |
|
| 40 |
// [iterator.cust.swap], ranges::iter_swap
|
| 41 |
+
inline constexpr unspecified iter_swap = unspecified; // freestanding
|
| 42 |
}
|
| 43 |
}
|
| 44 |
|
| 45 |
template<dereferenceable T>
|
| 46 |
requires requires(T& t) {
|
| 47 |
{ ranges::iter_move(t) } -> can-reference;
|
| 48 |
}
|
| 49 |
+
using iter_rvalue_reference_t // freestanding
|
| 50 |
= decltype(ranges::iter_move(declval<T&>()));
|
| 51 |
|
| 52 |
// [iterator.concepts], iterator concepts
|
| 53 |
// [iterator.concept.readable], concept indirectly_readable
|
| 54 |
template<class In>
|
| 55 |
+
concept indirectly_readable = see below; // freestanding
|
| 56 |
|
| 57 |
template<indirectly_readable T>
|
| 58 |
+
using indirect-value-t = see below; // exposition only
|
| 59 |
+
|
| 60 |
+
template<indirectly_readable T>
|
| 61 |
+
using iter_common_reference_t = // freestanding
|
| 62 |
+
common_reference_t<iter_reference_t<T>, indirect-value-t<T>>;
|
| 63 |
|
| 64 |
// [iterator.concept.writable], concept indirectly_writable
|
| 65 |
template<class Out, class T>
|
| 66 |
+
concept indirectly_writable = see below; // freestanding
|
| 67 |
|
| 68 |
// [iterator.concept.winc], concept weakly_incrementable
|
| 69 |
template<class I>
|
| 70 |
+
concept weakly_incrementable = see below; // freestanding
|
| 71 |
|
| 72 |
// [iterator.concept.inc], concept incrementable
|
| 73 |
template<class I>
|
| 74 |
+
concept incrementable = see below; // freestanding
|
| 75 |
|
| 76 |
// [iterator.concept.iterator], concept input_or_output_iterator
|
| 77 |
template<class I>
|
| 78 |
+
concept input_or_output_iterator = see below; // freestanding
|
| 79 |
|
| 80 |
// [iterator.concept.sentinel], concept sentinel_for
|
| 81 |
template<class S, class I>
|
| 82 |
+
concept sentinel_for = see below; // freestanding
|
| 83 |
|
| 84 |
// [iterator.concept.sizedsentinel], concept sized_sentinel_for
|
| 85 |
template<class S, class I>
|
| 86 |
+
constexpr bool disable_sized_sentinel_for = false; // freestanding
|
| 87 |
|
| 88 |
template<class S, class I>
|
| 89 |
+
concept sized_sentinel_for = see below; // freestanding
|
| 90 |
|
| 91 |
// [iterator.concept.input], concept input_iterator
|
| 92 |
template<class I>
|
| 93 |
+
concept input_iterator = see below; // freestanding
|
| 94 |
|
| 95 |
// [iterator.concept.output], concept output_iterator
|
| 96 |
template<class I, class T>
|
| 97 |
+
concept output_iterator = see below; // freestanding
|
| 98 |
|
| 99 |
// [iterator.concept.forward], concept forward_iterator
|
| 100 |
template<class I>
|
| 101 |
+
concept forward_iterator = see below; // freestanding
|
| 102 |
|
| 103 |
// [iterator.concept.bidir], concept bidirectional_iterator
|
| 104 |
template<class I>
|
| 105 |
+
concept bidirectional_iterator = see below; // freestanding
|
| 106 |
|
| 107 |
// [iterator.concept.random.access], concept random_access_iterator
|
| 108 |
template<class I>
|
| 109 |
+
concept random_access_iterator = see below; // freestanding
|
| 110 |
|
| 111 |
// [iterator.concept.contiguous], concept contiguous_iterator
|
| 112 |
template<class I>
|
| 113 |
+
concept contiguous_iterator = see below; // freestanding
|
| 114 |
|
| 115 |
// [indirectcallable], indirect callable requirements
|
| 116 |
// [indirectcallable.indirectinvocable], indirect callables
|
| 117 |
template<class F, class I>
|
| 118 |
+
concept indirectly_unary_invocable = see below; // freestanding
|
| 119 |
|
| 120 |
template<class F, class I>
|
| 121 |
+
concept indirectly_regular_unary_invocable = see below; // freestanding
|
| 122 |
|
| 123 |
template<class F, class I>
|
| 124 |
+
concept indirect_unary_predicate = see below; // freestanding
|
| 125 |
|
| 126 |
template<class F, class I1, class I2>
|
| 127 |
+
concept indirect_binary_predicate = see below; // freestanding
|
| 128 |
|
| 129 |
template<class F, class I1, class I2 = I1>
|
| 130 |
+
concept indirect_equivalence_relation = see below; // freestanding
|
| 131 |
|
| 132 |
template<class F, class I1, class I2 = I1>
|
| 133 |
+
concept indirect_strict_weak_order = see below; // freestanding
|
| 134 |
|
| 135 |
template<class F, class... Is>
|
| 136 |
requires (indirectly_readable<Is> && ...) && invocable<F, iter_reference_t<Is>...>
|
| 137 |
+
using indirect_result_t = invoke_result_t<F, iter_reference_t<Is>...>; // freestanding
|
| 138 |
|
| 139 |
// [projected], projected
|
| 140 |
template<indirectly_readable I, indirectly_regular_unary_invocable<I> Proj>
|
| 141 |
+
struct projected; // freestanding
|
| 142 |
|
| 143 |
template<weakly_incrementable I, class Proj>
|
| 144 |
+
struct incrementable_traits<projected<I, Proj>>; // freestanding
|
| 145 |
|
| 146 |
// [alg.req], common algorithm requirements
|
| 147 |
// [alg.req.ind.move], concept indirectly_movable
|
| 148 |
template<class In, class Out>
|
| 149 |
+
concept indirectly_movable = see below; // freestanding
|
| 150 |
|
| 151 |
template<class In, class Out>
|
| 152 |
+
concept indirectly_movable_storable = see below; // freestanding
|
| 153 |
|
| 154 |
// [alg.req.ind.copy], concept indirectly_copyable
|
| 155 |
template<class In, class Out>
|
| 156 |
+
concept indirectly_copyable = see below; // freestanding
|
| 157 |
|
| 158 |
template<class In, class Out>
|
| 159 |
+
concept indirectly_copyable_storable = see below; // freestanding
|
| 160 |
|
| 161 |
// [alg.req.ind.swap], concept indirectly_swappable
|
| 162 |
template<class I1, class I2 = I1>
|
| 163 |
+
concept indirectly_swappable = see below; // freestanding
|
| 164 |
|
| 165 |
// [alg.req.ind.cmp], concept indirectly_comparable
|
| 166 |
template<class I1, class I2, class R, class P1 = identity, class P2 = identity>
|
| 167 |
+
concept indirectly_comparable = see below; // freestanding
|
| 168 |
|
| 169 |
// [alg.req.permutable], concept permutable
|
| 170 |
template<class I>
|
| 171 |
+
concept permutable = see below; // freestanding
|
| 172 |
|
| 173 |
// [alg.req.mergeable], concept mergeable
|
| 174 |
template<class I1, class I2, class Out,
|
| 175 |
class R = ranges::less, class P1 = identity, class P2 = identity>
|
| 176 |
+
concept mergeable = see below; // freestanding
|
| 177 |
|
| 178 |
// [alg.req.sortable], concept sortable
|
| 179 |
template<class I, class R = ranges::less, class P = identity>
|
| 180 |
+
concept sortable = see below; // freestanding
|
| 181 |
|
| 182 |
// [iterator.primitives], primitives
|
| 183 |
// [std.iterator.tags], iterator tags
|
| 184 |
+
struct input_iterator_tag { }; // freestanding
|
| 185 |
+
struct output_iterator_tag { }; // freestanding
|
| 186 |
+
struct forward_iterator_tag: public input_iterator_tag { }; // freestanding
|
| 187 |
+
struct bidirectional_iterator_tag: public forward_iterator_tag { }; // freestanding
|
| 188 |
+
struct random_access_iterator_tag: public bidirectional_iterator_tag { }; // freestanding
|
| 189 |
+
struct contiguous_iterator_tag: public random_access_iterator_tag { }; // freestanding
|
| 190 |
|
| 191 |
// [iterator.operations], iterator operations
|
| 192 |
template<class InputIterator, class Distance>
|
| 193 |
constexpr void
|
| 194 |
+
advance(InputIterator& i, Distance n); // freestanding
|
| 195 |
template<class InputIterator>
|
| 196 |
constexpr typename iterator_traits<InputIterator>::difference_type
|
| 197 |
+
distance(InputIterator first, InputIterator last); // freestanding
|
| 198 |
template<class InputIterator>
|
| 199 |
constexpr InputIterator
|
| 200 |
+
next(InputIterator x, // freestanding
|
| 201 |
typename iterator_traits<InputIterator>::difference_type n = 1);
|
| 202 |
template<class BidirectionalIterator>
|
| 203 |
constexpr BidirectionalIterator
|
| 204 |
+
prev(BidirectionalIterator x, // freestanding
|
| 205 |
typename iterator_traits<BidirectionalIterator>::difference_type n = 1);
|
| 206 |
|
| 207 |
// [range.iter.ops], range iterator operations
|
| 208 |
namespace ranges {
|
| 209 |
// [range.iter.op.advance], ranges::advance
|
| 210 |
template<input_or_output_iterator I>
|
| 211 |
+
constexpr void advance(I& i, iter_difference_t<I> n); // freestanding
|
| 212 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 213 |
+
constexpr void advance(I& i, S bound); // freestanding
|
| 214 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 215 |
+
constexpr iter_difference_t<I> advance(I& i, iter_difference_t<I> n, // freestanding
|
| 216 |
+
S bound);
|
| 217 |
|
| 218 |
// [range.iter.op.distance], ranges::distance
|
| 219 |
+
template<class I, sentinel_for<I> S>
|
| 220 |
+
requires (!sized_sentinel_for<S, I>)
|
| 221 |
+
constexpr iter_difference_t<I> distance(I first, S last); // freestanding
|
| 222 |
+
template<class I, sized_sentinel_for<decay_t<I>> S>
|
| 223 |
+
constexpr iter_difference_t<decay_t<I>> distance(I&& first, S last); // freestanding
|
| 224 |
template<range R>
|
| 225 |
+
constexpr range_difference_t<R> distance(R&& r); // freestanding
|
| 226 |
|
| 227 |
// [range.iter.op.next], ranges::next
|
| 228 |
template<input_or_output_iterator I>
|
| 229 |
+
constexpr I next(I x); // freestanding
|
| 230 |
template<input_or_output_iterator I>
|
| 231 |
+
constexpr I next(I x, iter_difference_t<I> n); // freestanding
|
| 232 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 233 |
+
constexpr I next(I x, S bound); // freestanding
|
| 234 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 235 |
+
constexpr I next(I x, iter_difference_t<I> n, S bound); // freestanding
|
| 236 |
|
| 237 |
// [range.iter.op.prev], ranges::prev
|
| 238 |
template<bidirectional_iterator I>
|
| 239 |
+
constexpr I prev(I x); // freestanding
|
| 240 |
template<bidirectional_iterator I>
|
| 241 |
+
constexpr I prev(I x, iter_difference_t<I> n); // freestanding
|
| 242 |
template<bidirectional_iterator I>
|
| 243 |
+
constexpr I prev(I x, iter_difference_t<I> n, I bound); // freestanding
|
| 244 |
}
|
| 245 |
|
| 246 |
// [predef.iterators], predefined iterators and sentinels
|
| 247 |
// [reverse.iterators], reverse iterators
|
| 248 |
+
template<class Iterator> class reverse_iterator; // freestanding
|
| 249 |
|
| 250 |
template<class Iterator1, class Iterator2>
|
| 251 |
+
constexpr bool operator==( // freestanding
|
| 252 |
const reverse_iterator<Iterator1>& x,
|
| 253 |
const reverse_iterator<Iterator2>& y);
|
| 254 |
template<class Iterator1, class Iterator2>
|
| 255 |
+
constexpr bool operator!=( // freestanding
|
| 256 |
const reverse_iterator<Iterator1>& x,
|
| 257 |
const reverse_iterator<Iterator2>& y);
|
| 258 |
template<class Iterator1, class Iterator2>
|
| 259 |
+
constexpr bool operator<( // freestanding
|
| 260 |
const reverse_iterator<Iterator1>& x,
|
| 261 |
const reverse_iterator<Iterator2>& y);
|
| 262 |
template<class Iterator1, class Iterator2>
|
| 263 |
+
constexpr bool operator>( // freestanding
|
| 264 |
const reverse_iterator<Iterator1>& x,
|
| 265 |
const reverse_iterator<Iterator2>& y);
|
| 266 |
template<class Iterator1, class Iterator2>
|
| 267 |
+
constexpr bool operator<=( // freestanding
|
| 268 |
const reverse_iterator<Iterator1>& x,
|
| 269 |
const reverse_iterator<Iterator2>& y);
|
| 270 |
template<class Iterator1, class Iterator2>
|
| 271 |
+
constexpr bool operator>=( // freestanding
|
| 272 |
const reverse_iterator<Iterator1>& x,
|
| 273 |
const reverse_iterator<Iterator2>& y);
|
| 274 |
template<class Iterator1, three_way_comparable_with<Iterator1> Iterator2>
|
| 275 |
constexpr compare_three_way_result_t<Iterator1, Iterator2>
|
| 276 |
+
operator<=>(const reverse_iterator<Iterator1>& x, // freestanding
|
| 277 |
const reverse_iterator<Iterator2>& y);
|
| 278 |
|
| 279 |
template<class Iterator1, class Iterator2>
|
| 280 |
+
constexpr auto operator-( // freestanding
|
| 281 |
const reverse_iterator<Iterator1>& x,
|
| 282 |
const reverse_iterator<Iterator2>& y) -> decltype(y.base() - x.base());
|
| 283 |
template<class Iterator>
|
| 284 |
+
constexpr reverse_iterator<Iterator> operator+( // freestanding
|
| 285 |
+
iter_difference_t<Iterator> n,
|
|
|
|
| 286 |
const reverse_iterator<Iterator>& x);
|
| 287 |
|
| 288 |
template<class Iterator>
|
| 289 |
+
constexpr reverse_iterator<Iterator> make_reverse_iterator(Iterator i); // freestanding
|
| 290 |
|
| 291 |
template<class Iterator1, class Iterator2>
|
| 292 |
requires (!sized_sentinel_for<Iterator1, Iterator2>)
|
| 293 |
+
constexpr bool disable_sized_sentinel_for<reverse_iterator<Iterator1>, // freestanding
|
| 294 |
reverse_iterator<Iterator2>> = true;
|
| 295 |
|
| 296 |
// [insert.iterators], insert iterators
|
| 297 |
+
template<class Container> class back_insert_iterator; // freestanding
|
| 298 |
template<class Container>
|
| 299 |
+
constexpr back_insert_iterator<Container> back_inserter(Container& x); // freestanding
|
| 300 |
|
| 301 |
+
template<class Container> class front_insert_iterator; // freestanding
|
| 302 |
template<class Container>
|
| 303 |
+
constexpr front_insert_iterator<Container> front_inserter(Container& x); // freestanding
|
| 304 |
|
| 305 |
+
template<class Container> class insert_iterator; // freestanding
|
| 306 |
template<class Container>
|
| 307 |
constexpr insert_iterator<Container>
|
| 308 |
+
inserter(Container& x, ranges::iterator_t<Container> i); // freestanding
|
| 309 |
+
|
| 310 |
+
// [const.iterators], constant iterators and sentinels
|
| 311 |
+
// [const.iterators.alias], alias templates
|
| 312 |
+
template<indirectly_readable I>
|
| 313 |
+
using iter_const_reference_t = see below; // freestanding
|
| 314 |
+
template<class Iterator>
|
| 315 |
+
concept constant-iterator = see below; // exposition only
|
| 316 |
+
template<input_iterator I>
|
| 317 |
+
using const_iterator = see below; // freestanding
|
| 318 |
+
template<semiregular S>
|
| 319 |
+
using const_sentinel = see below; // freestanding
|
| 320 |
+
|
| 321 |
+
// [const.iterators.iterator], class template basic_const_iterator
|
| 322 |
+
template<input_iterator Iterator>
|
| 323 |
+
class basic_const_iterator; // freestanding
|
| 324 |
+
|
| 325 |
+
template<class T, common_with<T> U>
|
| 326 |
+
requires input_iterator<common_type_t<T, U>>
|
| 327 |
+
struct common_type<basic_const_iterator<T>, U> { // freestanding
|
| 328 |
+
using type = basic_const_iterator<common_type_t<T, U>>;
|
| 329 |
+
};
|
| 330 |
+
template<class T, common_with<T> U>
|
| 331 |
+
requires input_iterator<common_type_t<T, U>>
|
| 332 |
+
struct common_type<U, basic_const_iterator<T>> { // freestanding
|
| 333 |
+
using type = basic_const_iterator<common_type_t<T, U>>;
|
| 334 |
+
};
|
| 335 |
+
template<class T, common_with<T> U>
|
| 336 |
+
requires input_iterator<common_type_t<T, U>>
|
| 337 |
+
struct common_type<basic_const_iterator<T>, basic_const_iterator<U>> { // freestanding
|
| 338 |
+
using type = basic_const_iterator<common_type_t<T, U>>;
|
| 339 |
+
};
|
| 340 |
+
|
| 341 |
+
template<input_iterator I>
|
| 342 |
+
constexpr const_iterator<I> make_const_iterator(I it) { return it; } // freestanding
|
| 343 |
+
|
| 344 |
+
template<semiregular S>
|
| 345 |
+
constexpr const_sentinel<S> make_const_sentinel(S s) { return s; } // freestanding
|
| 346 |
|
| 347 |
// [move.iterators], move iterators and sentinels
|
| 348 |
+
template<class Iterator> class move_iterator; // freestanding
|
| 349 |
|
| 350 |
template<class Iterator1, class Iterator2>
|
| 351 |
+
constexpr bool operator==( // freestanding
|
| 352 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 353 |
template<class Iterator1, class Iterator2>
|
| 354 |
+
constexpr bool operator<( // freestanding
|
| 355 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 356 |
template<class Iterator1, class Iterator2>
|
| 357 |
+
constexpr bool operator>( // freestanding
|
| 358 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 359 |
template<class Iterator1, class Iterator2>
|
| 360 |
+
constexpr bool operator<=( // freestanding
|
| 361 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 362 |
template<class Iterator1, class Iterator2>
|
| 363 |
+
constexpr bool operator>=( // freestanding
|
| 364 |
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y);
|
| 365 |
template<class Iterator1, three_way_comparable_with<Iterator1> Iterator2>
|
| 366 |
constexpr compare_three_way_result_t<Iterator1, Iterator2>
|
| 367 |
+
operator<=>(const move_iterator<Iterator1>& x, // freestanding
|
| 368 |
const move_iterator<Iterator2>& y);
|
| 369 |
|
| 370 |
template<class Iterator1, class Iterator2>
|
| 371 |
+
constexpr auto operator-( // freestanding
|
| 372 |
+
const move_iterator<Iterator1>& x, const move_iterator<Iterator2>& y)
|
| 373 |
+
-> decltype(x.base() - y.base());
|
| 374 |
template<class Iterator>
|
| 375 |
+
constexpr move_iterator<Iterator>
|
| 376 |
+
operator+(iter_difference_t<Iterator> n, const move_iterator<Iterator>& x); // freestanding
|
| 377 |
|
| 378 |
template<class Iterator>
|
| 379 |
+
constexpr move_iterator<Iterator> make_move_iterator(Iterator i); // freestanding
|
| 380 |
|
| 381 |
+
template<class Iterator1, class Iterator2>
|
| 382 |
+
requires (!sized_sentinel_for<Iterator1, Iterator2>)
|
| 383 |
+
constexpr bool disable_sized_sentinel_for<move_iterator<Iterator1>, // freestanding
|
| 384 |
+
move_iterator<Iterator2>> = true;
|
| 385 |
+
|
| 386 |
+
template<semiregular S> class move_sentinel; // freestanding
|
| 387 |
|
| 388 |
// [iterators.common], common iterators
|
| 389 |
template<input_or_output_iterator I, sentinel_for<I> S>
|
| 390 |
requires (!same_as<I, S> && copyable<I>)
|
| 391 |
+
class common_iterator; // freestanding
|
| 392 |
|
| 393 |
template<class I, class S>
|
| 394 |
+
struct incrementable_traits<common_iterator<I, S>>; // freestanding
|
| 395 |
|
| 396 |
template<input_iterator I, class S>
|
| 397 |
+
struct iterator_traits<common_iterator<I, S>>; // freestanding
|
| 398 |
|
| 399 |
+
// [default.sentinel], default sentinel
|
| 400 |
+
struct default_sentinel_t; // freestanding
|
| 401 |
+
inline constexpr default_sentinel_t default_sentinel{}; // freestanding
|
| 402 |
|
| 403 |
// [iterators.counted], counted iterators
|
| 404 |
+
template<input_or_output_iterator I> class counted_iterator; // freestanding
|
|
|
|
|
|
|
|
|
|
| 405 |
|
| 406 |
template<input_iterator I>
|
| 407 |
+
requires see below
|
| 408 |
+
struct iterator_traits<counted_iterator<I>>; // freestanding
|
| 409 |
|
| 410 |
+
// [unreachable.sentinel], unreachable sentinel
|
| 411 |
+
struct unreachable_sentinel_t; // freestanding
|
| 412 |
+
inline constexpr unreachable_sentinel_t unreachable_sentinel{}; // freestanding
|
| 413 |
|
| 414 |
// [stream.iterators], stream iterators
|
| 415 |
template<class T, class charT = char, class traits = char_traits<charT>,
|
| 416 |
class Distance = ptrdiff_t>
|
| 417 |
class istream_iterator;
|
|
|
|
| 430 |
|
| 431 |
template<class charT, class traits = char_traits<charT>>
|
| 432 |
class ostreambuf_iterator;
|
| 433 |
|
| 434 |
// [iterator.range], range access
|
| 435 |
+
template<class C> constexpr auto begin(C& c) -> decltype(c.begin()); // freestanding
|
| 436 |
+
template<class C> constexpr auto begin(const C& c) -> decltype(c.begin()); // freestanding
|
| 437 |
+
template<class C> constexpr auto end(C& c) -> decltype(c.end()); // freestanding
|
| 438 |
+
template<class C> constexpr auto end(const C& c) -> decltype(c.end()); // freestanding
|
| 439 |
+
template<class T, size_t N> constexpr T* begin(T (&array)[N]) noexcept; // freestanding
|
| 440 |
+
template<class T, size_t N> constexpr T* end(T (&array)[N]) noexcept; // freestanding
|
| 441 |
+
template<class C> constexpr auto cbegin(const C& c) // freestanding
|
| 442 |
+
noexcept(noexcept(std::begin(c))) -> decltype(std::begin(c));
|
| 443 |
+
template<class C> constexpr auto cend(const C& c) // freestanding
|
| 444 |
+
noexcept(noexcept(std::end(c))) -> decltype(std::end(c));
|
| 445 |
+
template<class C> constexpr auto rbegin(C& c) -> decltype(c.rbegin()); // freestanding
|
| 446 |
+
template<class C> constexpr auto rbegin(const C& c) -> decltype(c.rbegin()); // freestanding
|
| 447 |
+
template<class C> constexpr auto rend(C& c) -> decltype(c.rend()); // freestanding
|
| 448 |
+
template<class C> constexpr auto rend(const C& c) -> decltype(c.rend()); // freestanding
|
| 449 |
+
template<class T, size_t N> constexpr reverse_iterator<T*> rbegin(T (&array)[N]) // freestanding
|
| 450 |
+
template<class T, size_t N> constexpr reverse_iterator<T*> rend(T (&array)[N]); // freestanding
|
| 451 |
+
template<class E> constexpr reverse_iterator<const E*>
|
| 452 |
+
rbegin(initializer_list<E> il); // freestanding
|
| 453 |
+
template<class E> constexpr reverse_iterator<const E*>
|
| 454 |
+
rend(initializer_list<E> il); // freestanding
|
| 455 |
+
template<class C> constexpr auto
|
| 456 |
+
crbegin(const C& c) -> decltype(std::rbegin(c)); // freestanding
|
| 457 |
+
template<class C> constexpr auto
|
| 458 |
+
crend(const C& c) -> decltype(std::rend(c)); // freestanding
|
| 459 |
|
| 460 |
+
template<class C> constexpr auto
|
| 461 |
+
size(const C& c) -> decltype(c.size()); // freestanding
|
| 462 |
+
template<class T, size_t N> constexpr size_t
|
| 463 |
+
size(const T (&array)[N]) noexcept; // freestanding
|
| 464 |
+
|
| 465 |
+
template<class C> constexpr auto
|
| 466 |
+
ssize(const C& c)
|
| 467 |
+
-> common_type_t<ptrdiff_t, make_signed_t<decltype(c.size())>>; // freestanding
|
| 468 |
+
template<class T, ptrdiff_t N> constexpr ptrdiff_t
|
| 469 |
+
ssize(const T (&array)[N]) noexcept; // freestanding
|
| 470 |
+
|
| 471 |
+
template<class C> [[nodiscard]] constexpr auto
|
| 472 |
+
empty(const C& c) -> decltype(c.empty()); // freestanding
|
| 473 |
+
template<class T, size_t N> [[nodiscard]] constexpr bool
|
| 474 |
+
empty(const T (&array)[N]) noexcept; // freestanding
|
| 475 |
+
template<class E> [[nodiscard]] constexpr bool
|
| 476 |
+
empty(initializer_list<E> il) noexcept; // freestanding
|
| 477 |
+
|
| 478 |
+
template<class C> constexpr auto data(C& c) -> decltype(c.data()); // freestanding
|
| 479 |
+
template<class C> constexpr auto data(const C& c) -> decltype(c.data()); // freestanding
|
| 480 |
+
template<class T, size_t N> constexpr T* data(T (&array)[N]) noexcept; // freestanding
|
| 481 |
+
template<class E> constexpr const E* data(initializer_list<E> il) noexcept; // freestanding
|
| 482 |
}
|
| 483 |
```
|
| 484 |
|