Boost logo

Boost :

From: Greg Colvin (greg_at_[hidden])
Date: 2002-05-02 17:21:56


At 02:19 PM 05/02/2002, Dave A wrote:
>From: "Andrei Alexandrescu" <andrewalex_at_[hidden]>
>...
>> > The beauty of Loki is that it IS a framework, and offers much
>> > power and convenience to those find it an appropriate framework.
>> >
>> > But the Standard Library, traditionally, is not so much a
>> > framework as a collection of utilities.
>> [snip]
>>
>> Just for the record, I completely disagree with the argument and
>comparison
>> above.
>
>For the record, I'm with Andrei on this one. At least, the 2nd statement
>seems completely wrong to me.

I'm backing off it.

I think it was true of the Standard C library, and is less true
of the Standard C++ library. But the C tradition was a big part
of the resistance to templatizing iostreams, and it was the STL
that finally broke past that tradition.

Even so, the C++ Standard leaves lots of implementation decisions
to the library implementer, and most of the generic hooks are for
supporting user types. Complex does not support user types at all,
and much of the extensibility of iostreams is via inheritance.
Allocators are an exception, and so far not a very successful one.
And the only smart pointer that made it into the standard, despite
lots of other work, and despite the desires of the library group,
was auto_ptr, which is customizable only on type. Note that the
objections to counted_ptr were never that it wasn't customizable
enough, but that people who needed it could just as well roll their
own, so why clutter up the standard?

So I have some fear that a Loki-style smart pointer could meet the
same fate as counted_ptr did, and that pushing it too hard might
prevent a simpler shared_ptr proposal from being accepted.


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