std::experimental::ranges:: MoveConstructible
From cppreference.net
<
cpp
|
experimental
|
ranges
C++
Experimental
| Technical Specification | ||||
| Filesystem library (filesystem TS) | ||||
| Library fundamentals (library fundamentals TS) | ||||
| Library fundamentals 2 (library fundamentals TS v2) | ||||
| Library fundamentals 3 (library fundamentals TS v3) | ||||
| Extensions for parallelism (parallelism TS) | ||||
| Extensions for parallelism 2 (parallelism TS v2) | ||||
| Extensions for concurrency (concurrency TS) | ||||
| Extensions for concurrency 2 (concurrency TS v2) | ||||
| Concepts (concepts TS) | ||||
| Ranges (ranges TS) | ||||
| Reflection (reflection TS) | ||||
| Mathematical special functions (special functions TR) | ||||
| Experimental Non-TS | ||||
| Pattern Matching | ||||
| Linear Algebra | ||||
| std::execution | ||||
| Contracts | ||||
| 2D Graphics |
Concepts library
| Core language concepts | ||||||||||||||||||
| Object concepts | ||||||||||||||||||
|
||||||||||||||||||
| Comparison concepts | ||||||||||||||||||
| Callable concepts | ||||||||||||||||||
| URNG concept | ||||||||||||||||||
|
template
<
class
T
>
concept
bool
MoveConstructible
=
|
(ranges TS) | |
当
T
为引用类型,或作为对象类型时,若该类型的对象能够通过右值在直接初始化和拷贝初始化上下文中按照常规语义构造,则满足
MoveConstructible
概念。
更准确地说,如果
T
是对象类型,则仅当满足以下条件时
MoveConstructible<T>
才成立:
-
rv,一个类型为T的右值,以及 -
u2,一个类型为T且等于rv的不同对象,
以下情况为真:
-
在定义
T u
=
rv
;
之后,
u等于u2; -
T{rv}等于u2;且 -
若
T非 const 限定,则rv的最终状态(在上述任一条目中的定义/表达式求值后)有效但未指定;否则其状态保持不变。
参见
|
(C++11)
(C++11)
(C++11)
|
检查类型是否可以从右值引用构造
(类模板) |