std::function_ref::operator()
来自 cppreference.cn
R operator()( Args... args ) const noexcept(/*noex*/); |
(C++26 起) | |
调用存储的 thunk-ptr
,将 bound-entity
作为其第一个参数,其余参数为 args
。operator() 的 /*noex*/ 部分与 std::function_ref
的模板参数的相同。
等效于 return thunk-ptr
(bound-entity
, std::forward<Args>(args)...);。
目录 |
[编辑] 参数
args | - | 传递给存储的 thunk-ptr 的其余参数 |
[编辑] 返回值
thunk-ptr
(bound-entity
, std::forward<Args>(args)...).
[编辑] 异常
传播底层函数调用所抛出的异常。
[编辑] 示例
本节不完整 原因:无示例 |
[编辑] 参阅
调用目标 ( std::function<R(Args...)> 的公共成员函数) | |
调用存储的函数 ( std::reference_wrapper<T> 的公共成员函数) |