"Aleksey Gurtovoy" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> [...]
>     typedef typename apply<
>           typename lambda<Policy>::type
>         , T
>         >::type p;
>
> things should work independently of whenever 'Policy' is in form of
> 'my_policy<_>' or 'my_policy' - given that the latter is a metafunction
> class, of course.

Never mind.  It all works as advertised.  I thought a class only had to
have a nested apply<> struct to be metafunction class, but it also
needs a typedef .. type; in the *apply*.  I think I tried putting in the
type,
but I put it outside of the apply, which was causing my problems.  It
seems odd that I have to say:

struct Policy
{
    template <typename P>
    struct apply
    {
        typedef apply type;
        // ...
    };
};

I guess that is to be consistent with metafunctions, but for some
reason I thought that lambda or mpl added the type for you.  Anyway,
all is well now.  Thanks for the help (Dave too).

Dave




_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Reply via email to