This is the mail archive of the libstdc++@sourceware.cygnus.com mailing list for the libstdc++ project.


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

RE: ostringstream buffers (was Re: stringstream status)



+ According to Edwards, Phil:
+ >- Contrary to the example in Stroustrup, 3rd.ed., the zero-arg ctor
+ >  never does anything.  Which, as you say, is what the standard seems to
+ >  say.  This is (as they say in the trade) a real bummer [...]
+ 
+ Well, could we please go with the sane:
+ 
+ >           ostringstream  o;
+ >           o << stuff << more stuff << stuff << ends;
+ >           return o.str();
+ 
+ ... even if it seems to have been overlooked in the standard?


I'd agree that something somewhere ain't quite right.  What's the point of
specifying an oSTRINGstream if it just bitbuckets data?  Although a "null
ostream" has occured to me before, requiring a stringstream just doesn't 
seem like the way to go.

Might this be a case for _G_RESOLVE_LIB_DEFECTS?  Or something along the
same lines?


Phil
(If you reply to the list, please don't cc another copy to me.  Thanks.)


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