This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: New STL implementation from SGI


On Thu, 9 Jul 1998, Joe Buck wrote:

> Actually I suspect that the SGI version will be slower as well as require
> more memory in some applications: if copying strings from place to place
> is common, but concatenation is less common,

Ouch! I've been happily using strings to pass around megabyte-sized
blobs of data, but reading about the SGI string class makes me want
to run and reread the spec to check on how portable my use is - I
thought C++ strings were *supposed* to have reference countng
semantics.

I'm all for including different implementations of the string class.
How about renaming basic_string to shallow_copy_basic_string and
deep_copy_basic_string respectively, and then have a mechanism to
choose which one is typedefed to basic_string - thereby allowing one
to write code that uses *both*?

-- 
     ,_
     /_)              /| /
    /   i e t e r    / |/ a g e l




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]