: Behaves as a formatted output function ([ostream.formatted.reqmts]
, except that:
- failure to generate output is reported as specified below, and
- any exception thrown by the call to vformat is propagated
without regard to the value of os.exceptions() and
without turning on ios_base::badbit in the error state of os.
After constructing a sentry object,
the function initializes an automatic variable via
string out = vformat(os.getloc(), fmt, args);
If the function is vprint_unicode
is a stream that refers to a terminal capable of displaying Unicode
which is determined in an implementation-defined manner,
to the terminal using the native Unicode API;
contains invalid code units,
the behavior is undefined and
implementations are encouraged to diagnose it.
If the native Unicode API is used,
the function flushes os
before writing out.
Otherwise (if os
is not such a stream or
the function is vprint_nonunicode
inserts the character sequence
) into os.
If writing to the terminal or inserting into os
(which may throw ios_base::failure