From: Arkadiy Vertleyb (vertleyb_at_[hidden])
Date: 2005-12-22 16:10:14
"Andy Little" <andy_at_[hidden]> wrote
> "Arkadiy Vertleyb" wrote
> > I believe the registration of a library types should reside inside this
> > library, and tested as a part of this library test.
> And if they dont then come the problems. Whether they do or not I need to
> it. At least a common format for eg the header name and location in the
> library-authors directories would help. I'm not expecting any other
> authors to add the typeof functionality that I need. I'm happy to do it
Right, but are you willing to _maintain_ this? At the same moment you are
adding your registrations, the library author might be changing his types...
I think who _does_ the initial work is not as important as who is
responsible for keeping it in-sync.
> but there needs to be a way to prevent multiple registrations. That means
> specifying some common format for everyone to use.
Some authors might prefer to register all their types in a separate file,
while others might want to register them in the same header where the types
are defined (this may depend on people's expectation of how much longer the
typeof emulation is going to be relevant).
One (although not perfect) way to avoid multiple registration problem was
suggested by David Abrahams some time ago -- to use guards similar to
// register mpl types
Now everybody has to agree on the guard name.
The ultimate solution would be persuade authors to register their types.
> >> > So that you can catch all of them at once instead of one-by-one, as
> >> > error messages arrive. Sounds reasonable.
> >> In VC7.1 they dont always arrive in the first place ;-)
> > Don't we always get something like:
> > "Type_not_registered_with_typeof_library=xxx<[a few hundred lines
> Removing one type registration from my quantities library I stopped the
> compilation at around 17000 lines of errror code.
> Whatever was at the top of it was something to do with
> which I had never heard of
> IOW No we dont ;-)
That's not good :-(
Can you post (or send me directly) the error message the next time you get
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk