摘要: 仿函数(functor): 重载了"()"运算符的struct,例如: struct D { D(int i=0){num=i;} int num; }; struct print_D{ void operator()(const D* d)const{ cout<<"I am D. my num="<<d->num<<endl; } }; in... 阅读全文
posted @ 2009-06-21 15:56 辛勤耕耘 阅读(577) 评论(0) 推荐(0)