Lumiera
0.pre.03
»edit your freedom«
|
Go to the source code of this file.
Capture previous settings of an std::ostream
and restore them when leaving scope.
The stream manipulators of the IOS-Framework from the C++ standard lib allow to adjust various aspects of output formatting for following data fed to the output stream. Unfortunately many of these settings are sticky and thus may "taint" common output streams like std::cout
. By planting this RAII capsule into a local scope, the internal settings of an output stream can be recorded and restored automatically, once control flow leaves the scope.
Definition in file ios-savepoint.hpp.
Classes | |
class | IosSavepoint |
RAII helper to capture and restore output stream format settings. More... | |