|
Boost : |
From: Boris Fomitchev (fbp_at_[hidden])
Date: 2000-01-07 19:09:36
Yep, I already admitted it - specialization makes it totally different.
I am not really thinking in partial specialization universe due to archaic
compilers I have to deal with ;). Unfortunately, in production world
the situation is even worse than in compiler world : you cannot switch
to the new compiler until (for example) your CORBA software vendor delivers the
library for this new compiler, and that could be (like in SUN case) years
apart...
So I do agree that specialization is the right way to design those things,
but, unfortunately, it cannot be really used now (and, in many environments,
2-3 years from now ;( ).
-Boris.
Dave Abrahams wrote:
> > Aleksey, your method should work ( I would still check this
> > addding printout statements).
> > No matter how wonderful such a method is and how useful
> > it could be to implement, say, synchronized containers,
> > my point was that using mutexes to synchronize shared_ptr
> > reference counting is a huge overkill - instead of changing
> > one instruction from simple increment to atomic one,
> > you would _add_ new data members and mutex syncronization
> > which is much more that atomic increment. Also, shared_ptr
> > does not neeed to be fully synchronized, only assignment does.
>
> I think you're missing the key advantage here, Boris: the mutexted<T>
> template could be specialized for shared_ptr (in a platform-specific way, of
> course) so as to avoid any unneccessary overheads.
>
> -Dave
>
> ------------------------------------------------------------------------
> Looking for educational tools for your kids?
> Find everything you need at SmarterKids.com
> http://click.egroups.com/1/645/1/_/9351/_/947288830/
>
> eGroups.com Home: http://www.egroups.com/group/boost/
> http://www.egroups.com - Simplifying group communications
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk