id stringlengths 16 145 | text stringlengths 1 179k | title stringclasses 1
value |
|---|---|---|
C++_Ranges_library/C++_Ranges_library_68_3.txt | gument is an lvalue (i.e. ` T ` is an lvalue reference type),
* const T otherwise.
A call to ` ranges::cbegin ` is [ expression-equivalent ](/w/cpp/language/expressions#Expression-equivalence "cpp/language/expressions") to [ ranges:: begin ](http://en.cppreference.com/w/cpp/ranges-ranges-placeholder/begin) ( ... | |
C++_Ranges_library/C++_Ranges_library_153_23.txt | ](/w/cpp/memory/shared_ptr/make_shared "cpp/memory/shared ptr/make shared") | 201707L | [ ` <memory> ` ](/w/cpp/header/memory "cpp/header/memory") | (C++20) | [ P0674R1 ](https://wg21.link/P0674R1)
` __cpp_lib_shared_ptr_weak_type ` | [ ` shared_ptr::weak_type ` ](/w/cpp/memory/shared_ptr "cpp/memory/shared pt... | |
C++_Ranges_library/C++_Ranges_library_56_6.txt | ty/any/bad any
cast") (since C++17)
[ ` bad_array_new_length ` ](/w/cpp/memory/new/bad_array_new_length
"cpp/memory/new/bad array new length") (since C++11)
[ ` bad_cast ` ](/w/cpp/types/bad_cast "cpp/types/bad cast")
[ ` bad_exception ` ](/w/cpp/error/bad_exception "cpp/error/bad exception")
[ ` bad_expected_a... | |
C++_Ranges_library/C++_Ranges_library_74_9.txt | ion ](/mwiki/index.php?title=cpp/coroutine/generator&action=info)
* In other languages
* [ Español ](http://es.cppreference.com/w/cpp/coroutine/generator "cpp/coroutine/generator")
* [ 日本語 ](http://ja.cppreference.com/w/cpp/coroutine/generator "cpp/coroutine/generator")
* [ Русский ](http://ru.cppreference.c... | |
C++_Ranges_library/C++_Ranges_library_61_3.txt | models ` range ` only if
* ` [ ` [ ranges:: begin ](http://en.cppreference.com/w/cpp/ranges-ranges-placeholder/begin) ( E ) ` , ` [ ranges:: end ](http://en.cppreference.com/w/cpp/ranges-ranges-placeholder/end) ( E ) ` ) ` denotes a [ range ](/w/cpp/iterator#Ranges "cpp/iterator") , and
* both [ ranges... | |
C++_Ranges_library/C++_Ranges_library_23_13.txt | lib_ranges_to_container ` ](/w/cpp/feature_test#cpp_lib_ranges_to_container "cpp/feature test") | 202202L | (C++23) | std::ranges::to
[ ` __cpp_lib_ranges_zip ` ](/w/cpp/feature_test#cpp_lib_ranges_zip "cpp/feature test") | 202110L | (C++23) | std::ranges::zip_view ,
std::ranges::zip_transform_view , ... | |
C++_Ranges_library/C++_Ranges_library_59_22.txt | ized_sentinel_for<S, I> ? subrange_kind::sized : subrange_kind::unsized>
requires (K == subrange_kind::sized || !sized_sentinel_for<S, I>)
class subrange : public view_interface<subrange<I, S, K>> {
private:
static constexpr bool StoreSize = // exposition only
... | |
C++_Ranges_library/C++_Ranges_library_117_1.txt | cpp/ranges/iterator t")
---
| [ iterator_t const_iterator_t sentinel_t const_sentinel_t
](/w/cpp/ranges/iterator_t "cpp/ranges/iterator t") (C++23) (C++23)
---
| [ range_const_reference_t range_rvalue_reference_t
range_common_reference_t ](/w/cpp/ranges/iterator_t "cpp/ranges/iterator t")
(C++23) ... | |
C++_Ranges_library/checking-cin-input-stream-produces-an-integer9_27_0.txt | asked Sep 10, 2013 at 21:06
user2766546 user2766546 | |
C++_Ranges_library/C++_Ranges_library_57_1.txt | `
#elif ` ](/w/cpp/preprocessor/conditional "cpp/preprocessor/conditional") . It
is treated as a defined macro by [ ` #ifdef `
](/w/cpp/preprocessor/conditional "cpp/preprocessor/conditional") , [ `
#ifndef ` ](/w/cpp/preprocessor/conditional "cpp/preprocessor/conditional") ,
[ ` #elifdef ` ](/w/cpp/preprocessor/condi... | |
C++_Ranges_library/C++_Ranges_library_26_3.txt | erator_ :: _iterator_
](/w/cpp/ranges/transform_view/iterator/iterator "cpp/ranges/transform
view/iterator/iterator")
[ transform_view:: _iterator_ ::base
](/w/cpp/ranges/transform_view/iterator/base "cpp/ranges/transform
view/iterator/base")
[ transform_view:: _iterator_ ::operator*
](/w/cpp/ranges/transform_view/... | |
C++_Ranges_library/C++_Ranges_library_97_1.txt | erence_t
](/w/cpp/ranges/iterator_t "cpp/ranges/iterator t")
---
| [ iterator_t const_iterator_t sentinel_t const_sentinel_t
](/w/cpp/ranges/iterator_t "cpp/ranges/iterator t") (C++23) (C++23)
---
| [ range_const_reference_t range_rvalue_reference_t
range_common_reference_t ](/w/cpp/ranges/iterato... | |
C++_Ranges_library/C++_Ranges_library_31_38.txt | ### Navigation
* [ Support us ](http://www.cppreference.com/support)
* [ Recent changes ](/w/Special:RecentChanges "A list of recent changes in the wiki \[r\]")
* [ FAQ ](/w/Cppreference:FAQ)
* [ Offline version ](/w/Cppreference:Archives)
##### Toolbox
* [ What links here ](/w/Special:WhatLinksHere/cpp/... | |
C++_Ranges_library/C++_Ranges_library_128_14.txt | ru.cppreference.com/w/cpp/ranges "cpp/ranges")
* [ 中文 ](http://zh.cppreference.com/w/cpp/ranges "cpp/ranges")
* This page was last modified on 23 March 2024, at 06:26.
* This page has been accessed 999,598 times.
* [ Privacy policy ](/w/Cppreference:Privacy_policy "Cppreference:Privacy policy")
* [ About ... | |
C++_Ranges_library/C++_Ranges_library_126_27.txt | rary
# include <boost/optional.hpp>
# else // Not found at all
# error "Missing <optional>"
# endif
#endif
#ifdef __has_cpp_attribute // Check if __has_cpp_attribute is present
# if __has_cpp_attribute(deprecated) ... | |
C++_Ranges_library/C++_Ranges_library_3_22.txt | https://wg21.link/P1206R7)
` __cpp_lib_ranges_zip ` | std::ranges::zip_view , std::ranges::zip_transform_view , std::ranges::adjacent_view , std::ranges::adjacent_transform_view | 202110L | [ ` <ranges> ` ](/w/cpp/header/ranges "cpp/header/ranges") [ ` <tuple> ` ](/w/cpp/header/tuple "cpp/header/tuple") [ ... | |
C++_Ranges_library/checking-cin-input-stream-produces-an-integer9_123_0.txt | 1
My code fails to verify input as an integer | |
C++_Ranges_library/C++_Ranges_library_134_5.txt | ldid=158239)
"
##### Navigation
* [ Support us ](http://www.cppreference.com/support)
* [ Recent changes ](/w/Special:RecentChanges "A list of recent changes in the wiki \[r\]")
* [ FAQ ](/w/Cppreference:FAQ)
* [ Offline version ](/w/Cppreference:Archives)
##### Toolbox
* [ What links here ](/w/Special:... | |
C++_Ranges_library/C++_Ranges_library_117_5.txt | hp?title=Template:cpp/ranges/view_interface/dsc_empty&action=edit)
[ cbegin ](/w/cpp/ranges/view_interface/cbegin "cpp/ranges/view interface/cbegin") (C++23) | returns a constant iterator to the beginning of the range.
(public member function of ` std::ranges::view_interface<D> ` ) [ [edit]
](https://en.cppref... | |
C++_Ranges_library/C++_Ranges_library_64_13.txt | ") | (C++20) | [ P1001R2 ](https://wg21.link/P1001R2)
` __cpp_lib_expected ` | class template std::expected | 202202L | [ ` <expected> ` ](/w/cpp/header/expected "cpp/header/expected") | (C++23) | [ P0323R12 ](https://wg21.link/P0323R12)
Monadic functions for std::expected | 202211L | [ ` <expected... | |
C++_Ranges_library/C++_Ranges_library_32_16.txt | decltype(c.rbegin());
template<class C> constexpr auto rbegin(const C& c) -> decltype(c.rbegin());
template<class C> constexpr auto rend(C& c) -> decltype(c.rend());
template<class C> constexpr auto rend(const C& c) -> decltype(c.rend());
template<class T, size_t N> constexpr reverse_iterator<T... | |
C++_Ranges_library/C++_Ranges_library_73_32.txt | this_parameter)
COMPILER_FEATURE_ENTRY(202106L, __cpp_if_consteval)
COMPILER_FEATURE_ENTRY(202207L, __cpp_implicit_move)
COMPILER_FEATURE_ENTRY(202211L, __cpp_multidimensional_subscript)
COMPILER_FEATURE_ENTRY(202207L, __cpp_named_character_escapes)
COMPILER_FEATURE_ENTRY(202211L... | |
C++_Ranges_library/C++_Ranges_library_64_4.txt | gory "cpp/language/value category") | 201606L | (C++17) | [ P0135R1 ](https://wg21.link/P0135R1)
` __cpp_hex_float ` | [ Hexadecimal floating literals ](/w/cpp/language/floating_literal "cpp/language/floating literal") | 201603L | (C++17) | [ P0245R1 ](https://wg21.link/P0245R1)
` __cpp_if_consteval ` | ... | |
C++_Ranges_library/C++_Ranges_library_90_2.txt | ges/lazy_split_view
"cpp/ranges/lazy split view")
[ split_view views::split ](/w/cpp/ranges/split_view "cpp/ranges/split
view")
** views::counted **
[ common_view views::common ](/w/cpp/ranges/common_view "cpp/ranges/common
view")
| [ reverse_view views::reverse ](/w/cpp/ranges/reverse_view
"cp... | |
C++_Ranges_library/C++_Ranges_library_2_9.txt | ](/w/cpp/ranges/adjacent_view "cpp/ranges/adjacent view") (C++23) | a [ ` view ` ](/w/cpp/ranges/view "cpp/ranges/view") consisting of tuples of references to adjacent elements of the adapted view
(class template) (range adaptor object) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/r... | |
C++_Ranges_library/C++_Ranges_library_91_10.txt | tle=Template:cpp/algorithm/ranges/dsc_fill_n&action=edit)
[ generate ](/w/cpp/algorithm/generate "cpp/algorithm/generate") | assigns the results of successive function calls to every element in a range
(function template) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/dsc_ge... | |
C++_Ranges_library/C++_Ranges_library_78_2.txt | ion=edit§ion=2 "Edit
section: Library contents") ] Library contents
The C++ standard library provides definitions for the [ entities
](/w/cpp/language/basic_concepts "cpp/language/basic concepts") and [ macros
](/w/cpp/preprocessor/replace "cpp/preprocessor/replace") described in the
synopses of the [ C++ standar... | |
C++_Ranges_library/C++_Ranges_library_57_15.txt | | Freestanding std::mdspan | 202311L | [ ` <mdspan> ` ](/w/cpp/header/mdspan "cpp/header/mdspan") | (C++26) | [ P2833R2 ](https://wg21.link/P2833R2)
` __cpp_lib_freestanding_memory ` | Freestanding facilities in [ ` <memory> ` ](/w/cpp/header/memory "cpp/header/memory") | 202306L | [ ` <memory> ` ](/w/c... | |
C++_Ranges_library/C++_Ranges_library_86_0.txt | ##### [ cppreference.com ](/)
[ Log in
](/mwiki/index.php?title=Special:UserLogin&returnto=cpp%2Franges%2Frange+adaptor+closure
"You are encouraged to log in; however, it is not mandatory \[o\]")
##### Namespaces
* [ Page ](/w/cpp/ranges/range_adaptor_closure "View the content page \[c\]")
* [ Discussion ](/mw... | |
C++_Ranges_library/C++_Ranges_library_58_5.txt | if it satisfies [ ` sized_range ` ](/w/cpp/ranges/sized_range "cpp/ranges/sized range") or [ ` forward_range ` ](/w/cpp/ranges/forward_range "cpp/ranges/forward range") .
(public member function of ` std::ranges::view_interface<D> ` ) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/ranges/... | |
C++_Ranges_library/C++_Ranges_library_56_31.txt | emory/new/new_handler "cpp/memory/new/new
handler")
[ ` next<>() ` ](/w/cpp/iterator/next "cpp/iterator/next") (since C++11)
[ ` next_permutation<>() ` ](/w/cpp/algorithm/next_permutation
"cpp/algorithm/next permutation")
[ ` nextafter() ` ](/w/cpp/numeric/math/nextafter
"cpp/numeric/math/nextafter") (since C++11... | |
C++_Ranges_library/C++_Ranges_library_124_1.txt | p/language/expressions") ( [ precedence
](/w/cpp/language/operator_precedence "cpp/language/operator precedence") )
[ Conversions ](/w/cpp/language/expressions#Conversions
"cpp/language/expressions") − [ Literals
](/w/cpp/language/expressions#Literals "cpp/language/expressions")
[ Statements ](/w/cpp/language/state... | |
C++_Ranges_library/C++_Ranges_library_82_8.txt | e first N elements of a sequence
(niebloid) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_for_each_n&action=edit)
[ ranges::count ranges::count_if ](/w/cpp/algorithm/ranges/count "cpp/algorithm/ranges/count") (C++20) (C++20) | returns the number of elements sa... | |
C++_Ranges_library/param-pack.html4_52_0.txt | Suppose you want to add two tuples, element by element. You could use two
nested lambdas to expand the two tuples in succession, but this would be a bit
awkward. Instead, you can use ` std::make_index_sequence ` to get the tuple
indices, then use the indices in a pattern that accesses the elements of both
tuples elemen... | |
C++_Ranges_library/C++_Ranges_library_63_6.txt | [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/ranges/dsc_as_const_view&action=edit)
Retrieved from " [
https://en.cppreference.com/mwiki/index.php?title=cpp/ranges/as_rvalue_view&oldid=159645
](https://en.cppreference.com/mwiki/index.php?title=cpp/ranges/as_rvalue_view&oldid=159645)
"
... | |
C++_Ranges_library/C++_Ranges_library_85_2.txt | with view") (C++23) (C++23)
[ lazy_split_view views::lazy_split ](/w/cpp/ranges/lazy_split_view
"cpp/ranges/lazy split view")
[ split_view views::split ](/w/cpp/ranges/split_view "cpp/ranges/split
view")
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted")
[ common_view views::common... | |
C++_Ranges_library/C++_Ranges_library_73_15.txt | | Freestanding std::mdspan | 202311L | [ ` <mdspan> ` ](/w/cpp/header/mdspan "cpp/header/mdspan") | (C++26) | [ P2833R2 ](https://wg21.link/P2833R2)
` __cpp_lib_freestanding_memory ` | Freestanding facilities in [ ` <memory> ` ](/w/cpp/header/memory "cpp/header/memory") | 202306L | [ ` <memory> ` ](/w/c... | |
C++_Ranges_library/C++_Ranges_library_34_9.txt | specifies that values may be moved from an [ ` indirectly_readable ` ](/w/cpp/iterator/indirectly_readable "cpp/iterator/indirectly readable") type to an [ ` indirectly_writable ` ](/w/cpp/iterator/indirectly_writable "cpp/iterator/indirectly writable") type and that the move may be performed via an intermediate object... | |
C++_Ranges_library/C++_Ranges_library_15_2.txt | ranges/split_view "cpp/ranges/split
view")
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted")
[ common_view views::common ](/w/cpp/ranges/common_view "cpp/ranges/common
view")
| [ reverse_view views::reverse ](/w/cpp/ranges/reverse_view
"cpp/ranges/reverse view")
---
[ as_... | |
C++_Ranges_library/C++_Ranges_library_30_3.txt | herwise.
A call to ` ranges::cend ` is [ expression-equivalent ](/w/cpp/language/expressions#Expression-equivalence "cpp/language/expressions") to [ ranges:: end ](http://en.cppreference.com/w/cpp/ranges-ranges-placeholder/end) ( static_cast < CT && > ( t ) ) . | (until C++23)
---|---
If the argument... | |
C++_Ranges_library/C++_Ranges_library_88_14.txt | ru.cppreference.com/w/cpp/ranges "cpp/ranges")
* [ 中文 ](http://zh.cppreference.com/w/cpp/ranges "cpp/ranges")
* This page was last modified on 23 March 2024, at 06:26.
* This page has been accessed 999,598 times.
* [ Privacy policy ](/w/Cppreference:Privacy_policy "Cppreference:Privacy policy")
* [ About ... | |
C++_Ranges_library/C++_Ranges_library_34_10.txt | wiki/index.php?title=Template:cpp/iterator/dsc_projected&action=edit)
[ projected_value_t ](/w/cpp/iterator/projected_value_t "cpp/iterator/projected value t") (C++26) | computes the value type of an [ ` indirectly_readable ` ](/w/cpp/iterator/indirectly_readable "cpp/iterator/indirectly readable") type by project... | |
C++_Ranges_library/C++_Ranges_library_23_11.txt | > )
return const_cast < const R & > ( r ) ;
else
return r ;
} | (1) | ( exposition only* )
---|---|---
template < class T >
constexpr auto /* as-const-pointer */ ( const T * p ) noexcept
{
return p ;
} | (2) | ( exposition only* )
| |
Some range access ... | |
C++_Ranges_library/C++_Ranges_library_14_3.txt | mplate:cpp/locale/dsc_ctype_char&action=edit)
[ codecvt ](/w/cpp/locale/codecvt "cpp/locale/codecvt") | converts between character encodings, including UTF-8, UTF-16, UTF-32
(class template) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/locale/dsc_codecvt&action=edit)
[ codecvt_byn... | |
C++_Ranges_library/C++_Ranges_library_67_9.txt | ](/w/cpp/ranges/adjacent_view "cpp/ranges/adjacent view") (C++23) | a [ ` view ` ](/w/cpp/ranges/view "cpp/ranges/view") consisting of tuples of references to adjacent elements of the adapted view
(class template) (range adaptor object) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/r... | |
C++_Ranges_library/C++_Ranges_library_11_26.txt | ](/w/cpp/header/tuple "cpp/header/tuple") [ ` <utility> ` ](/w/cpp/header/utility "cpp/header/utility") | (C++14) | [ N3670 ](https://wg21.link/N3670)
` __cpp_lib_type_identity ` | std::type_identity | 201806L | [ ` <type_traits> ` ](/w/cpp/header/type_traits "cpp/header/type traits") | (C++20) | [ P0887R1... | |
C++_Ranges_library/C++_Ranges_library_57_31.txt | 01907L, __cpp_lib_barrier)
COMPILER_FEATURE_ENTRY(201907L, __cpp_lib_bind_front)
COMPILER_FEATURE_ENTRY(201806L, __cpp_lib_bit_cast)
COMPILER_FEATURE_ENTRY(201907L, __cpp_lib_bitops)
COMPILER_FEATURE_ENTRY(201902L, __cpp_lib_bounded_array_traits)
COMPILER_FEATURE_ENTRY(201907L, _... | |
C++_Ranges_library/C++_Ranges_library_70_1.txt | `
#elif ` ](/w/cpp/preprocessor/conditional "cpp/preprocessor/conditional") . It
is treated as a defined macro by [ ` #ifdef `
](/w/cpp/preprocessor/conditional "cpp/preprocessor/conditional") , [ `
#ifndef ` ](/w/cpp/preprocessor/conditional "cpp/preprocessor/conditional") ,
[ ` #elifdef ` ](/w/cpp/preprocessor/condi... | |
C++_Ranges_library/C++_Ranges_library_64_34.txt | COMPILER_FEATURE_ENTRY(202306L, __cpp_lib_not_fn)
COMPILER_FEATURE_ENTRY(202311L, __cpp_lib_out_ptr)
COMPILER_FEATURE_ENTRY(202311L, __cpp_lib_ranges_as_const)
COMPILER_FEATURE_ENTRY(202306L, __cpp_lib_ratio)
COMPILER_FEATURE_ENTRY(202306L, __cpp_lib_rcu)
COMPILER_FEATURE... | |
C++_Ranges_library/C++_Ranges_library_64_0.txt | ##### [ cppreference.com ](/)
[ Log in
](/mwiki/index.php?title=Special:UserLogin&returnto=cpp%2Ffeature+test "You
are encouraged to log in; however, it is not mandatory \[o\]")
##### Namespaces
* [ Page ](/w/cpp/feature_test "View the content page \[c\]")
* [ Discussion ](/w/Talk:cpp/feature_test "Discussion ... | |
C++_Ranges_library/C++_Ranges_library_109_38.txt | ### Navigation
* [ Support us ](http://www.cppreference.com/support)
* [ Recent changes ](/w/Special:RecentChanges "A list of recent changes in the wiki \[r\]")
* [ FAQ ](/w/Cppreference:FAQ)
* [ Offline version ](/w/Cppreference:Archives)
##### Toolbox
* [ What links here ](/w/Special:WhatLinksHere/cpp/... | |
C++_Ranges_library/C++_Ranges_library_23_2.txt | counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted")
[ common_view views::common ](/w/cpp/ranges/common_view "cpp/ranges/common
view")
| [ reverse_view views::reverse ](/w/cpp/ranges/reverse_view
"cpp/ranges/reverse view")
---
[ as_const_view views::as_const ](/w/cpp/ranges/as_const_... | |
C++_Ranges_library/C++_Ranges_library_130_23.txt | ](/w/cpp/memory/shared_ptr/make_shared "cpp/memory/shared ptr/make shared") | 201707L | [ ` <memory> ` ](/w/cpp/header/memory "cpp/header/memory") | (C++20) | [ P0674R1 ](https://wg21.link/P0674R1)
` __cpp_lib_shared_ptr_weak_type ` | [ ` shared_ptr::weak_type ` ](/w/cpp/memory/shared_ptr "cpp/memory/shared pt... | |
C++_Ranges_library/C++_Ranges_library_56_34.txt | since C++11)
[ ` ratio_equal ` ](/w/cpp/numeric/ratio/ratio_equal "cpp/numeric/ratio/ratio
equal") <> (since C++11)
[ ` ratio_equal_v ` ](/w/cpp/numeric/ratio/ratio_equal
"cpp/numeric/ratio/ratio equal") <> (since C++17)
[ ` ratio_greater ` ](/w/cpp/numeric/ratio/ratio_greater
"cpp/numeric/ratio/ratio greater") <... | |
C++_Ranges_library/C++_Ranges_library_3_10.txt | ](https://wg21.link/P2592R3)
` __cpp_lib_chrono_udls ` | [ User-defined literals for time types ](/w/cpp/chrono/duration#Literals "cpp/chrono/duration") | 201304L | [ ` <chrono> ` ](/w/cpp/header/chrono "cpp/header/chrono") | (C++14) | [ N3642 ](https://wg21.link/N3642)
` __cpp_lib_clamp ` | [ std::clamp ]... | |
C++_Ranges_library/checking-cin-input-stream-produces-an-integer9_87_0.txt | Add a comment |
0 | |
C++_Ranges_library/C++_Ranges_library_3_3.txt | https://wg21.link/P1668R1)
Changing the active member of a union in constant evaluation | 202002L | (C++20) | [ P1330R0 ](https://wg21.link/P1330R0)
[ P2493R0 ](https://wg21.link/P2493R0)
Non- [ literal ](/w/cpp/named_req/LiteralType "cpp/named req/LiteralType") variables, labels, and [ ` goto ` ](/w/cpp/l... | |
C++_Ranges_library/C++_Ranges_library_85_7.txt | alues_view "cpp/ranges/values view") (C++20) | takes a [ ` view ` ](/w/cpp/ranges/view "cpp/ranges/view") consisting of pair-like values and produces a [ ` view ` ](/w/cpp/ranges/view "cpp/ranges/view") of the second elements of each pair
(class template) (range adaptor object) [ [edit]
](https://en.cppreference... | |
C++_Ranges_library/C++_Ranges_library_95_36.txt | or/end)(cxx11_core), add);
if (print.cxx98) [std::for_each](http://en.cppreference.com/w/cpp/algorithm/for_each)([std::begin](http://en.cppreference.com/w/cpp/iterator/begin)(cxx98_core), [std::end](http://en.cppreference.com/w/cpp/iterator/end)(cxx98_core), add);
[std::snprintf](http://en.cppre... | |
C++_Ranges_library/C++_Ranges_library_40_6.txt | er the derived view is empty. Provided if it satisfies [ ` sized_range ` ](/w/cpp/ranges/sized_range "cpp/ranges/sized range") or [ ` forward_range ` ](/w/cpp/ranges/forward_range "cpp/ranges/forward range") .
(public member function of ` std::ranges::view_interface<D> ` ) [ [edit]
](https://en.cppreference.com/mwi... | |
C++_Ranges_library/param-pack.html4_73_0.txt | * When you take a reference type ` TR ` and add an rvalue reference, you get back ` TR ` , meaning ` TR&& ` and ` TR ` are always the same type for a reference. When you add an lvalue reference to reference type ` TR ` , you always get back an lvalue reference, meaning ` TR& ` is always the same as ` std::remove_refe... | |
C++_Ranges_library/param-pack.html4_40_0.txt | The most basic variadic template idiom, probably already known to most people
reading this blog post, is to iterate over the argument list recursively,
using function overloading to differentiate the base case (no arguments) from
the recursive case (one or more). A silly example:
inline void
printall... | |
C++_Ranges_library/C++_Ranges_library_82_9.txt | hether a range starts with another range
(niebloid) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_starts_with&action=edit)
[ ranges::ends_with ](/w/cpp/algorithm/ranges/ends_with "cpp/algorithm/ranges/ends with") (C++23) | checks whether a range ends with anothe... | |
C++_Ranges_library/C++_Ranges_library_152_2.txt | /ranges/lazy_split_view
"cpp/ranges/lazy split view")
[ split_view views::split ](/w/cpp/ranges/split_view "cpp/ranges/split
view")
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted")
[ common_view views::common ](/w/cpp/ranges/common_view "cpp/ranges/common
view")
| [ revers... | |
C++_Ranges_library/C++_Ranges_library_51_7.txt | [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/ranges/dsc_owning_view&action=edit)
[ ranges::filter_view views::filter ](/w/cpp/ranges/filter_view "cpp/ranges/filter view") (C++20) | a [ ` view ` ](/w/cpp/ranges/view "cpp/ranges/view") that consists of the elements of a [ ` range ` ](... | |
C++_Ranges_library/C++_Ranges_library_10_16.txt | h range") [ | ` push_range `
--- ](/w/cpp/container/queue/push_range "cpp/container/queue/push range") [ | ` push_range `
--- ](/w/cpp/container/priority_queue/push_range "cpp/container/priority queue/push range") | | | | | ` append_range `
---
| ` emplace_back `
---
| | [ | ` emplace_back ... | |
C++_Ranges_library/C++_Ranges_library_143_4.txt | io ` ](/w/cpp/feature_test#cpp_lib_freestanding_ratio "cpp/feature test") | 202306L | (C++26) | freestanding [ ` <ratio> ` ](/w/cpp/header/ratio "cpp/header/ratio")
[ ` __cpp_lib_freestanding_string_view ` ](/w/cpp/feature_test#cpp_lib_freestanding_string_view "cpp/feature test") | 202311L | (C++26) | frees... | |
C++_Ranges_library/C++_Ranges_library_32_1.txt | tjmp> ` ](/w/cpp/header/csetjmp "cpp/header/csetjmp")
[ ` <cstdarg> ` ](/w/cpp/header/cstdarg "cpp/header/cstdarg")
Concepts
[ ` <concepts> ` ](/w/cpp/header/concepts "cpp/header/concepts") (C++20)
Diagnostics
| [ ` <stdexcept> ` ](/w/cpp/header/stdexcept "cpp/header/stdexcept")
---
[ ` <stacktr... | |
C++_Ranges_library/C++_Ranges_library_110_14.txt | ru.cppreference.com/w/cpp/ranges "cpp/ranges")
* [ 中文 ](http://zh.cppreference.com/w/cpp/ranges "cpp/ranges")
* This page was last modified on 23 March 2024, at 06:26.
* This page has been accessed 999,598 times.
* [ Privacy policy ](/w/Cppreference:Privacy_policy "Cppreference:Privacy policy")
* [ About ... | |
C++_Ranges_library/C++_Ranges_library_31_27.txt | rary
# include <boost/optional.hpp>
# else // Not found at all
# error "Missing <optional>"
# endif
#endif
#ifdef __has_cpp_attribute // Check if __has_cpp_attribute is present
# if __has_cpp_attribute(deprecated) ... | |
C++_Ranges_library/C++_Ranges_library_153_9.txt | s://wg21.link/P2714R1)
` __cpp_lib_bit_cast ` | [ ` std::bit_cast ` ](/w/cpp/numeric/bit_cast "cpp/numeric/bit cast") | 201806L | [ ` <bit> ` ](/w/cpp/header/bit "cpp/header/bit") | (C++20) | [ P0476R2 ](https://wg21.link/P0476R2)
` __cpp_lib_bitops ` | [ Bit operations ](/w/cpp/numeric#Bit_manipulation_.28... | |
C++_Ranges_library/C++_Ranges_library_153_6.txt | ents ](/w/cpp/language/template_parameters#Template_template_arguments "cpp/language/template parameters") | 201611L | (C++17) | [ P0522R0 ](https://wg21.link/P0522R0)
` __cpp_threadsafe_static_init ` | [ Dynamic initialization and destruction with concurrency ](/w/cpp/language/storage_duration#Static_local_var... | |
C++_Ranges_library/checking-cin-input-stream-produces-an-integer9_148_0.txt | ##### Company
* About
* Press
* Work Here
* Legal
* Privacy Policy
* Terms of Service
* Contact Us
* Cookie Settings
* Cookie Policy | |
C++_Ranges_library/C++_Ranges_library_2_8.txt | range adaptor object) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/ranges/dsc_lazy_split_view&action=edit)
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted") (C++20) | creates a subrange from an iterator and a count
(customization point object) [ [edit]
](htt... | |
C++_Ranges_library/C++_Ranges_library_6_0.txt | ##### [ cppreference.com ](/)
[ Log in ](/mwiki/index.php?title=Special:UserLogin&returnto=cpp%2Fstring "You
are encouraged to log in; however, it is not mandatory \[o\]")
##### Namespaces
* [ Page ](/w/cpp/string "View the content page \[c\]")
* [ Discussion ](/mwiki/index.php?title=Talk:cpp/string&action=edi... | |
C++_Ranges_library/C++_Ranges_library_153_33.txt | RE_ENTRY(202110L, __cpp_lib_ranges_zip)
COMPILER_FEATURE_ENTRY(202202L, __cpp_lib_reference_from_temporary)
COMPILER_FEATURE_ENTRY(202202L, __cpp_lib_shift)
COMPILER_FEATURE_ENTRY(202106L, __cpp_lib_spanstream)
COMPILER_FEATURE_ENTRY(202011L, __cpp_lib_stacktrace)
COMPILER_FEATUR... | |
C++_Ranges_library/C++_Ranges_library_32_21.txt | =T-27
"Template:cpp/synopsis/iterator") ] Concept [ ` mergeable `
](/w/cpp/iterator/mergeable "cpp/iterator/mergeable")
namespace std {
template<class I1, class I2, class Out, class R = [ranges::less](http://en.cppreference.com/w/cpp/ranges-functional-placeholder/less),
class P1 = i... | |
C++_Ranges_library/C++_Ranges_library_141_8.txt | set> ` ](/w/cpp/header/unordered_set "cpp/header/unordered set") | (C++26) | [ P2363R5 ](https://wg21.link/P2363R5)
` __cpp_lib_assume_aligned ` | [ std::assume_aligned ](/w/cpp/memory/assume_aligned "cpp/memory/assume aligned") | 201811L | [ ` <memory> ` ](/w/cpp/header/memory "cpp/header/memory") | (C++20) ... | |
C++_Ranges_library/C++_Ranges_library_57_22.txt | https://wg21.link/P1206R7)
` __cpp_lib_ranges_zip ` | std::ranges::zip_view , std::ranges::zip_transform_view , std::ranges::adjacent_view , std::ranges::adjacent_transform_view | 202110L | [ ` <ranges> ` ](/w/cpp/header/ranges "cpp/header/ranges") [ ` <tuple> ` ](/w/cpp/header/tuple "cpp/header/tuple") [ ... | |
C++_Ranges_library/C++_Ranges_library_135_2.txt | ew
"cpp/ranges/lazy split view")
[ split_view views::split ](/w/cpp/ranges/split_view "cpp/ranges/split
view")
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted")
[ common_view views::common ](/w/cpp/ranges/common_view "cpp/ranges/common
view")
| [ reverse_view views::revers... | |
C++_Ranges_library/param-pack.html4_26_0.txt | For all other binary operators, a unary fold over an empty parameter pack
results in an ill-formed program.
## Capturing parameter packs | |
C++_Ranges_library/C++_Ranges_library_100_2.txt | [ split_view views::split ](/w/cpp/ranges/split_view "cpp/ranges/split
view")
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted")
[ common_view views::common ](/w/cpp/ranges/common_view "cpp/ranges/common
view")
| [ reverse_view views::reverse ](/w/cpp/ranges/reverse_view
"cp... | |
C++_Ranges_library/C++_Ranges_library_10_0.txt | ##### [ cppreference.com ](/)
[ Log in ](/mwiki/index.php?title=Special:UserLogin&returnto=cpp%2Fcontainer
"You are encouraged to log in; however, it is not mandatory \[o\]")
##### Namespaces
* [ Page ](/w/cpp/container "View the content page \[c\]")
* [ Discussion ](/w/Talk:cpp/container "Discussion about the... | |
C++_Ranges_library/C++_Ranges_library_31_29.txt | cxx14_lib[] = {
COMPILER_FEATURE_ENTRY(201304L, __cpp_lib_chrono_udls)
COMPILER_FEATURE_ENTRY(201309L, __cpp_lib_complex_udls)
COMPILER_FEATURE_ENTRY(201304L, __cpp_lib_exchange_function)
COMPILER_FEATURE_ENTRY(201304L, __cpp_lib_generic_associative_lookup)
COMPILER_FEATURE_ENTRY... | |
C++_Ranges_library/C++_Ranges_library_77_3.txt | ge ` concept is a refinement of [ ` range `
](/w/cpp/ranges/range "cpp/ranges/range") for which ` ranges::begin ` returns
a [ constant iterator ](/w/cpp/iterator#Iterator_categories "cpp/iterator") .
2) The exposition-only concept /*constant-iterator*/ < T > is satisfied
when the result of the indirection operatio... | |
C++_Ranges_library/C++_Ranges_library_11_9.txt | s://wg21.link/P2714R1)
` __cpp_lib_bit_cast ` | [ ` std::bit_cast ` ](/w/cpp/numeric/bit_cast "cpp/numeric/bit cast") | 201806L | [ ` <bit> ` ](/w/cpp/header/bit "cpp/header/bit") | (C++20) | [ P0476R2 ](https://wg21.link/P0476R2)
` __cpp_lib_bitops ` | [ Bit operations ](/w/cpp/numeric#Bit_manipulation_.28... | |
C++_Ranges_library/C++_Ranges_library_46_3.txt | ordered_map "cpp/header/unordered map") [ ` <unordered_set> ` ](/w/cpp/header/unordered_set "cpp/header/unordered set")
` __cpp_lib_assume_aligned ` | 201811L | [ ` <memory> ` ](/w/cpp/header/memory "cpp/header/memory")
` __cpp_lib_atomic_flag_test ` | 201907L | [ ` <atomic> ` ](/w/cpp/header/atomic "cpp/head... | |
C++_Ranges_library/what-will-be-the-output-of-the-following-c-code--5ab8a41bc56b6664bc9bacdd8_26_0.txt | return 0;
} | |
C++_Ranges_library/C++_Ranges_library_31_3.txt | https://wg21.link/P1668R1)
Changing the active member of a union in constant evaluation | 202002L | (C++20) | [ P1330R0 ](https://wg21.link/P1330R0)
[ P2493R0 ](https://wg21.link/P2493R0)
Non- [ literal ](/w/cpp/named_req/LiteralType "cpp/named req/LiteralType") variables, labels, and [ ` goto ` ](/w/cpp/l... | |
C++_Ranges_library/C++_Ranges_library_67_8.txt | range adaptor object) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/ranges/dsc_lazy_split_view&action=edit)
[ views::counted ](/w/cpp/ranges/view_counted "cpp/ranges/view counted") (C++20) | creates a subrange from an iterator and a count
(customization point object) [ [edit]
](htt... | |
C++_Ranges_library/C++_Ranges_library_31_2.txt | ct initialization ](/w/cpp/language/direct_initialization "cpp/language/direct initialization") | 201902L | (C++20) | [ P0960R3 ](https://wg21.link/P0960R3)
` __cpp_alias_templates ` | [ Alias templates ](/w/cpp/language/type_alias "cpp/language/type alias") | 200704L | (C++11) | [ N2258 ](https://wg21.lin... | |
C++_Ranges_library/C++_Ranges_library_88_13.txt | lib_ranges_to_container ` ](/w/cpp/feature_test#cpp_lib_ranges_to_container "cpp/feature test") | 202202L | (C++23) | std::ranges::to
[ ` __cpp_lib_ranges_zip ` ](/w/cpp/feature_test#cpp_lib_ranges_zip "cpp/feature test") | 202110L | (C++23) | std::ranges::zip_view ,
std::ranges::zip_transform_view , ... | |
C++_Ranges_library/C++_Ranges_library_85_1.txt |
| [ iterator_t const_iterator_t sentinel_t const_sentinel_t
](/w/cpp/ranges/iterator_t "cpp/ranges/iterator t") (C++23) (C++23)
---
| [ range_const_reference_t range_rvalue_reference_t
range_common_reference_t ](/w/cpp/ranges/iterator_t "cpp/ranges/iterator t")
(C++23)
---
| [ elements_of ... | |
C++_Ranges_library/C++_Ranges_library_151_4.txt | ressions#Expression-
equivalence "cpp/language/expressions") to stride_view ( e, n ) .
The ` n ` must be greater than 0 , otherwise the behavior is
undefined.
` stride_view ` always models [ ` input_range ` ](/w/cpp/ranges/input_range
"cpp/ranges/input range") , and models [ ` forward_range `
](/w/cpp/ra... | |
C++_Ranges_library/C++_Ranges_library_130_0.txt | ##### [ cppreference.com ](/)
[ Log in
](/mwiki/index.php?title=Special:UserLogin&returnto=cpp%2Ffeature+test "You
are encouraged to log in; however, it is not mandatory \[o\]")
##### Namespaces
* [ Page ](/w/cpp/feature_test "View the content page \[c\]")
* [ Discussion ](/w/Talk:cpp/feature_test "Discussion ... | |
C++_Ranges_library/param-pack.html4_20_0.txt | ## Folds
Another special form of pack expansion is folds , introduced in C++17.
Above, we showed a function ` sum ` that summed a set of integers. This
function can be implemented far more concisely with a fold: | |
C++_Ranges_library/C++_Ranges_library_130_28.txt | xpect },
#endif
#define COMPILER_SPECIFIC_STRING(value) #value
#define COMPILER_SPECIFIC_ENTRY(name) { #name, COMPILER_SPECIFIC_STRING(name) },
class CompilerFeature
{
char const* name_; long data_; long std_;
public:
constexpr CompilerFeature(char const* name, long d... | |
C++_Ranges_library/C++_Ranges_library_60_3.txt | /error/get_unexpected "cpp/error/get unexpected") (C++11) (removed in C++17) | obtains the current unexpected_handler
(function) [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/error/dsc_get_unexpected&action=edit)
[ set_unexpected ](/w/cpp/error/set_unexpected "cpp/error/set unexpec... | |
C++_Ranges_library/C++_Ranges_library_136_22.txt | https://wg21.link/P1206R7)
` __cpp_lib_ranges_zip ` | std::ranges::zip_view , std::ranges::zip_transform_view , std::ranges::adjacent_view , std::ranges::adjacent_transform_view | 202110L | [ ` <ranges> ` ](/w/cpp/header/ranges "cpp/header/ranges") [ ` <tuple> ` ](/w/cpp/header/tuple "cpp/header/tuple") [ ... | |
C++_Ranges_library/C++_Ranges_library_70_32.txt | this_parameter)
COMPILER_FEATURE_ENTRY(202106L, __cpp_if_consteval)
COMPILER_FEATURE_ENTRY(202207L, __cpp_implicit_move)
COMPILER_FEATURE_ENTRY(202211L, __cpp_multidimensional_subscript)
COMPILER_FEATURE_ENTRY(202207L, __cpp_named_character_escapes)
COMPILER_FEATURE_ENTRY(202211L... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.