|
-
May 27th, 2010, 09:06 PM
#11
Re: Functor Tutorial
PS: There are other advantages to functors, like typedef-ing, or functor organization (I'm thinking "unary_function" etc.)
PS2: In 99% of the cases, the inline cost is actually free, because the functor is nothing more than a wrapper to "operator<".
What is the advantage of functor organization in the case of a class is derived from unary_function ?
In my opinion, functor not just "is nothing more than a wrapper to "operator<". " but normally it is designed as a predicate for looping construct.
Why you say functor is a wrapper for operator< ?
Please comment.
Thanks for your help.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|