basic_stringbuf::overflow
virtual int_type overflow(int_type c =
traits_type::eof());If c does not compare equal to traits_type::eof(), the protected virtual member function endeavors to insert the element traits_type::to_char_type(c) into the output buffer. It can do so in various ways:
- If a write position is available, it can store the element into the write position and increment the next pointer for the output buffer.
- It can make a write position available by allocating new or additional storage for the output buffer. (Extending the output buffer this way also extends any associated input buffer.)
If the function cannot succeed, it returns traits_type::eof(). Otherwise, it returns traits_type::not_eof(c).