cpp/io/basic streambuf/pbackfail

This function can only be called if any of the following condition is satisfied:
 * is null,
 * , or
 * returns.

This function is called by the public functions sungetc and sputbackc (which, in turn, are called by and ) when either: @1@ There is no putback position in the get area ( is called with no arguments). In this situation, the purpose of is to back up the get area by one character, if the associated character sequence allows this (e.g. a file-backed streambuf may reload the buffer from a file, starting one character earlier). @2@ The caller attempts to putback a different character from the one retrieved earlier ( is called with the character that needs to be put back). In this situation, the purpose of is to place the character  into the get area at the position just before, and, if possible, to modify the associated character sequence to reflect this change. This may involve backing up the get area as in the first variant.

The default base class version of this function does nothing and returns in all situations. This function is overridden by the derived classes:, , , and is expected to be overridden by user-defined and third-party library stream classes.

Return value
in case of failure, some other value to indicate success. The base class version always fails.