std::experimental:: negation
|
ヘッダーで定義
<experimental/type_traits>
|
||
|
template
<
class
B
>
struct negation ; |
(1) | (library fundamentals TS v2) |
型特性
B
の論理否定を形成します。
型 negation < B > は、 UnaryTypeTrait であり、基本特性は std:: integral_constant < bool , ! bool ( B :: value ) > です。
目次 |
テンプレートパラメータ
| B | - | 式 bool ( B :: value ) が有効な定数式となる任意の型 |
ヘルパー変数テンプレート
|
template
<
class
B
>
constexpr bool negation_v = negation < B > :: value ; |
(ライブラリファンダメンタルTS v2) | |
std:: integral_constant から継承
メンバ定数
|
value
[static]
|
true
(
B
がメンバ
::value
を持ち、
!
bool
(
B
::
value
)
が
true
の場合)、
false
(それ以外の場合)
(public static member constant) |
メンバ関数
|
operator bool
|
オブジェクトを
bool
に変換し、
value
を返す
(public member function) |
|
operator()
(C++14)
|
value
を返す
(public member function) |
メンバ型
| 型 | 定義 |
value_type
|
bool |
type
|
std:: integral_constant < bool , value > |
実装例
template<class B> struct negation : std::integral_constant<bool, !bool(B::value)> {}; |
例
|
このセクションは不完全です
理由: 例がありません |
関連項目
|
(C++17)
|
論理NOTメタ関数
(クラステンプレート) |