目录

assign

描述 (Description)

它用f初始化目标。 alloc用于为函数可能使用的任何内部数据结构分配内存。

声明 (Declaration)

以下是std :: function :: assign的声明。

C++11

template< class F, class Alloc >

C++17

void assign( F&& f, const Alloc& alloc );

参数 (Parameters)

  • other - 此函数对象用于初始化* this。

  • f - 用于初始化* this的callable。

返回值 (Return Value)

没有

异常 (Exceptions)

没有

↑回到顶部↑
WIKI教程 @2018