Topic: Differences in strstreams and stringstreams


Author: clamage@Eng.Sun.COM (Steve Clamage)
Date: 1995/04/11
Raw View
In article 5u7@hermes.unt.edu, johnw@jove.acs.unt.edu (John Robert Williams) writes:
>I heard a while ago that strstreams are now stringstreams. Will there be
>any major differences bewteen the two?

Stringstreams were added to iostreams, using the standard string class
as the basis of the associated streambuf. (Strstreams used a char array.)

Because of the difficulty of using strstreams, and some inherent dangers,
strstreams were dropped from the standard (or perhaps relegated to a
"deprecated features" appendix -- I'm not certain of the current status).

Usage of the two kinds of streams is similar but not identical, reflecting
the essential differences between a string class and a simple char array.
Watch for an announcement of the public availability of the draft
standard and you can look it up. I can't possibly post the details in a
netnews article.
---
Steve Clamage, stephen.clamage@eng.sun.com