Namespaces
Variants

std:: bit_not<void>

From cppreference.net
Utilities library
Function objects
Function invocation
(C++17) (C++23)
Identity function object
(C++20)
Old binders and adaptors
( until C++17* )
( until C++17* )
( until C++17* )
( until C++17* )
( until C++17* ) ( until C++17* ) ( until C++17* ) ( until C++17* )
( until C++20* )
( until C++20* )
( until C++17* ) ( until C++17* )
( until C++17* ) ( until C++17* )

( until C++17* )
( until C++17* ) ( until C++17* ) ( until C++17* ) ( until C++17* )
( until C++20* )
( until C++20* )
定义于头文件 <functional>
template <>
class bit_not < void > ;
(C++14 起)

std:: bit_not < void > std::bit_not 的特化版本,其参数和返回类型由编译器推导得出。

目录

嵌套类型

嵌套类型 定义
is_transparent 未指定

成员函数

operator()
对其参数应用 operator~
(公开成员函数)

std::bit_not<void>:: operator()

template < class T >

constexpr auto operator ( ) ( T && arg ) const

- > decltype ( ~ std:: forward < T > ( arg ) ) ;

返回 ~ std:: forward < T > ( arg ) 的结果。

参数

arg - 要进行按位非运算的值

返回值

~ std:: forward < T > ( arg )

示例