vendredi 22 mai 2015

C++ Functors explanation

Could you please explain following statements with example

Statement1

Ordinary functions have different types only when their signatures differ. However, function objects can have different types when their signatures are the same. In fact, each functional behavior defined by a function object has its own type. This is a significant improvement for generic programming using templates because you can pass functional behavior as a template parameter

Aucun commentaire:

Enregistrer un commentaire