34#pragma GCC system_header
44namespace std _GLIBCXX_VISIBILITY(default)
46_GLIBCXX_BEGIN_NAMESPACE_VERSION
48 template<
typename _Facet>
50 __check_facet(
const _Facet* __f)
69 template<
typename _CharT,
typename _Traits>
72#if __cplusplus >= 202002L
73 static_assert(is_same_v<_CharT, typename _Traits::char_type>);
105 mutable bool _M_fill_init;
123#if __cplusplus >= 201103L
125 explicit operator bool()
const
126 {
return !this->
fail(); }
128 operator void*()
const
135 {
return this->
fail(); }
148 {
return _M_streambuf_state; }
174 _M_setstate(iostate __state)
178 _M_streambuf_state |= __state;
180 { __throw_exception_again; }
192 {
return this->
rdstate() == 0; }
238 {
return _M_exception; }
274 _M_exception = __except;
275 this->
clear(_M_streambuf_state);
286 : ios_base(), _M_tie(0), _M_fill(), _M_fill_init(false), _M_streambuf(0),
287 _M_ctype(0), _M_num_put(0), _M_num_get(0)
288 { this->
init(__sb); }
339 {
return _M_streambuf; }
390 if (__builtin_expect(!_M_fill_init,
false))
391 return this->
widen(
' ');
447 {
return __check_facet(_M_ctype).narrow(__c, __dfault); }
466 {
return __check_facet(_M_ctype).widen(__c); }
477 : ios_base(), _M_tie(0), _M_fill(
char_type()), _M_fill_init(false),
478 _M_streambuf(0), _M_ctype(0), _M_num_put(0), _M_num_get(0)
490#if __cplusplus >= 201103L
497 ios_base::_M_move(__rhs);
498 _M_cache_locale(_M_ios_locale);
499 this->
tie(__rhs.
tie(
nullptr));
500 _M_fill = __rhs._M_fill;
501 _M_fill_init = __rhs._M_fill_init;
502 _M_streambuf =
nullptr;
507 { this->
move(__rhs); }
512 ios_base::_M_swap(__rhs);
513 _M_cache_locale(_M_ios_locale);
514 __rhs._M_cache_locale(__rhs._M_ios_locale);
515 std::swap(_M_tie, __rhs._M_tie);
516 std::swap(_M_fill, __rhs._M_fill);
517 std::swap(_M_fill_init, __rhs._M_fill_init);
521 set_rdbuf(basic_streambuf<_CharT, _Traits>* __sb)
522 { _M_streambuf = __sb; }
526 _M_cache_locale(
const locale& __loc);
529_GLIBCXX_END_NAMESPACE_VERSION
constexpr std::remove_reference< _Tp >::type && move(_Tp &&__t) noexcept
Convert a value to an rvalue.
ISO C++ entities toplevel namespace is std.
Template class basic_ios, virtual base class for all stream classes.
void clear(iostate __state=goodbit)
[Re]sets the error state.
bool eof() const
Fast error checking.
locale imbue(const locale &__loc)
Moves to a new locale.
basic_streambuf< _CharT, _Traits > * rdbuf(basic_streambuf< _CharT, _Traits > *__sb)
Changing the underlying buffer.
ctype< char_type > __ctype_type
traits_type::pos_type pos_type
basic_ostream< _CharT, _Traits > * tie() const
Fetches the current tied stream.
iostate exceptions() const
Throwing exceptions on errors.
void setstate(iostate __state)
Sets additional flags in the error state.
bool operator!() const
The quick-and-easy status check.
basic_ios & copyfmt(const basic_ios &__rhs)
Copies fields of __rhs into this.
char_type fill(char_type __ch)
Sets a new empty character.
iostate rdstate() const
Returns the error state of the stream buffer.
void init(basic_streambuf< _CharT, _Traits > *__sb)
All setup is performed here.
bool good() const
Fast error checking.
char_type widen(char __c) const
Widens characters.
char_type fill() const
Retrieves the empty character.
char narrow(char_type __c, char __dfault) const
Squeezes characters.
virtual ~basic_ios()
Empty.
traits_type::off_type off_type
bool fail() const
Fast error checking.
basic_ostream< _CharT, _Traits > * tie(basic_ostream< _CharT, _Traits > *__tiestr)
Ties this stream to an output stream.
basic_streambuf< _CharT, _Traits > * rdbuf() const
Accessing the underlying buffer.
traits_type::int_type int_type
num_put< char_type, ostreambuf_iterator< char_type, traits_type > > __num_put_type
num_get< char_type, istreambuf_iterator< char_type, traits_type > > __num_get_type
bool bad() const
Fast error checking.
basic_ios(basic_streambuf< _CharT, _Traits > *__sb)
Constructor performs initialization.
void exceptions(iostate __except)
Throwing exceptions on errors.
The actual work of input and output (interface).
Template class basic_ostream.
static const iostate eofbit
static const iostate goodbit
static const iostate badbit
static const iostate failbit
Container class for localization functionality.
Primary class template ctype facet.
Primary class template num_get.
Primary class template num_put.