Boost logo

Boost Users :

From: nobody (yg-boost-users_at_[hidden])
Date: 2002-09-26 10:08:51


Peter Dimov wrote:
> Because I haven't written the doc yet. :-)

;-))) I was assuming this was some sort of old code I was reading,
because it is the most straight forward version of a smart pointer I
could think of. Well... it seems to be (part of) the future then.

>>typedefing std::auto_ptr to boost::single_ptr?
> What would the purpose, assuming that you can typedef a template?

Having everything in one namespace with a uniform naming scheme...
auto_ptr doesn't say much, does it?

>>notifying_ptr
> Yes, this might be useful. It requires the ability to enumerate all pointers
> to a given object, which the current implementation doesn't provide. I'm not
> yet sure whether this should be "left to the reader" or be a part of the
> library.

No, no ;) Very much of boost as well as stl is very short "trivial"
code with only one purpose: Make it a standard everybody should at least
have heard of.

And I don't think this one is soooo easy to do as a simple "reader"; I
guess a good implementation would use bind so it does not have to send
some generic "notify" message. I wouldn't even know if I sould store the
vector<notifying_ptr> in the object pointed to (maybe as a superclass)
or in an extra object (which should could be a major performance
impact). Maybe this discussion should move to the developer list, but
that one is to busy for me ;-)

Regards


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net