27 Input/output library [input.output]

27.5 Iostreams base classes [iostreams.base]

27.5.5 Class template basic_ios [ios] basic_ios constructors [basic.ios.cons]

explicit basic_ios(basic_streambuf<charT,traits>* sb);

Effects: Constructs an object of class basic_ios, assigning initial values to its member objects by calling init(sb).


Effects: Constructs an object of class basic_ios ([ios.base.cons]) leaving its member objects uninitialized. The object shall be initialized by calling basic_ios::init before its first use or before it is destroyed, whichever comes first; otherwise the behavior is undefined.


Remarks: The destructor does not destroy rdbuf().

void init(basic_streambuf<charT,traits>* sb);

Postconditions: The postconditions of this function are indicated in Table [tab:iostreams.basicios.init.effects].

Table 128basic_ios::init() effects
rdbuf() sb
tie() 0
rdstate() goodbit if sb is not a null pointer, otherwise badbit.
exceptions() goodbit
flags() skipws | dec
width() 0
precision() 6
fill() widen(' ');
getloc() a copy of the value returned by locale()
iarray a null pointer
parray a null pointer