Boost logo

Boost :

From: Arkadiy Vertleyb (vertleyb_at_[hidden])
Date: 2006-05-15 10:33:11


"Peter Dimov" <pdimov_at_[hidden]> wrote

> Arkadiy Vertleyb wrote:
> > "David Abrahams" <dave_at_[hidden]> wrote
> >
> >> So, do we *have* typeof registrations for the lambda and bind
> >> libraries?
> >
> > Not AFAIK.
> >
> >> From the libraries currently in Boost, only spirit and xpressive had
> >> there types registered.
> >
> > I would love to see lambda/bind to register their types, but this
> > should be done by the library authors (or some volonteers intimately
> > familiar with these libraries). Any help would be happily provided.
>
> This is the usual dependency problem with new (hence optional)
> infrastructure. People using TYPEOF would ideally just #include
> <boost/bind.hpp> and have it all work. People _not_ using TYPEOF would
> ideally #include <boost/bind.hpp> and _not_ have it include any other
> headers that are of no interest to them. Unfortunately we can't have it
both
> ways. Can we?

No, but I like the approach Eric used in xpressive:

1) have the types forward-declared;
2) register all the types in a separate file (something like
bind_typeof.hpp).

To use typeof then, one would have to include bind_typeof.hpp, and whichever
headers from bind are needed.

Regards,
Arkadiy


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk