std::copy_constructible
From cppreference.com
 
 
 
 
 
 C++ 
 Feature test macros (C++20)
 Concepts library (C++20)
 Metaprogramming library (C++11)
 Ranges library (C++20)
 Filesystem library (C++17)
 Concurrency support library (C++11)
 Execution control library (C++26)
Concepts library 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)(C++20)
(C++20)
(C++20)
(C++20)
  (C++20)
copy_constructible
(C++20)
(C++20)
(C++20)(C++20)
(C++20)(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
(C++20)(C++20)
(C++20)
(C++20)
(C++20)
(C++20)
 Exposition-only concepts
 (C++20)
Defined in header 
 
 
<concepts> 
 template< class T >
 
 (since C++20) 
concept copy_constructible =
    std::move_constructible <T> &&
    std::constructible_from <T, T&> && std::convertible_to <T&, T> &&
    std::constructible_from <T, const T&> && std::convertible_to <const T&, T> &&
The concept copy_constructible is satisfied if T is an lvalue reference type, or if it is a move_constructible object type where an object of that type can constructed from a (possibly const) lvalue or const rvalue of that type in both direct- and copy-initialization contexts with the usual semantics (a copy is constructed with the source unchanged).
[edit] Semantic requirements
If T is an object type, then copy_constructible<T> is modeled only if given
- v, an lvalue of type (possibly const) T or an rvalue of type const T,
the following are true:
- After the definition T u = v;, u is equal to v and v is not modified;
- T(v) is equal to v and does not modify v.
[edit] References
- C++23 standard (ISO/IEC 14882:2024):
-  18.4.14 Concept copy_constructible[concept.copyconstructible]
 
-  18.4.14 Concept 
- C++20 standard (ISO/IEC 14882:2020):
-  18.4.14 Concept copy_constructible[concept.copyconstructible]
 
-  18.4.14 Concept