STD::ISTRINGSTREAM(3)

๐Ÿ’– NAME ๐Ÿ’–

okay so bestie, welcome to the manual page for std::basic_istringstream< _CharT, _Traits, _Alloc >(3) โ€” it's giving Library Functions Manual energy, and it's literally all about Controlling input for std::string. no cap.


โœจ SYNOPSIS โœจ

#include <sstream>

Inherits std::basic_istream< _CharT, _Traits >.

๐ŸŒธ Public Types ๐ŸŒธ

  • typedef ctype< _CharT > __ctype_type โ€” a typedef, iconic.
  • typedef basic_ios< _CharT, _Traits > __ios_type โ€” another typedef moment.
  • typedef basic_istream< char_type, traits_type > __istream_type โ€” yes, typedef.
  • typedef num_get< _CharT, istreambuf_iterator< _CharT, _Traits > > __num_get_type โ€” typedef, slay.
  • typedef basic_streambuf< _CharT, _Traits > __streambuf_type โ€” typedef vibes.
  • typedef basic_string< _CharT, _Traits, _Alloc > __string_type โ€” the string type, periodt.
  • typedef basic_stringbuf< _CharT, _Traits, _Alloc > __stringbuf_type โ€” the stringbuf type.
  • typedef _Alloc allocator_type โ€” allocator type, as promised.
  • typedef _CharT char_type โ€” char type.
  • enum event { erase_event, imbue_event, copyfmt_event } โ€” The set of events that may be passed to an event callback.
  • typedef void(* event_callback) (event __e, ios_base &__b, int __i) โ€” The type of an event callback function.
  • typedef _Ios_Fmtflags fmtflags โ€” This is a bitmask type.
  • typedef traits_type::int_type int_type โ€” int_type, okay.
  • typedef _Ios_Iostate iostate โ€” This is a bitmask type.
  • typedef traits_type::off_type off_type โ€” off_type, yes.
  • typedef _Ios_Openmode openmode โ€” This is a bitmask type.
  • typedef traits_type::pos_type pos_type โ€” pos_type, fr fr.
  • typedef _Ios_Seekdir seekdir โ€” This is an enumerated type.
  • typedef _Traits traits_type โ€” traits type, lowkey essential.
  • typedef num_put< _CharT, ostreambuf_iterator< _CharT, _Traits > > __num_put_type โ€” yep, another typedef, we love to see it.

๐Ÿ‘‘ Public Member Functions ๐Ÿ‘‘

  • basic_istringstream () โ€” Default constructor starts with an empty string buffer.
  • basic_istringstream (__string_type &&__str, ios_base::openmode __mode=ios_base::in) โ€” rvalue string constructor, with __mode defaulting to ios_base::in.
  • basic_istringstream (basic_istringstream &&__rhs) โ€” move constructor, main character energy.
  • basic_istringstream (const __string_type &__str, ios_base::openmode __mode=ios_base::in) โ€” Starts with an existing string buffer.
  • basic_istringstream (const basic_istringstream &)=delete โ€” copy constructor is deleted, bestie. not available.
  • template<typename _SAlloc> basic_istringstream (const basic_string< _CharT, _Traits, _SAlloc > &__str, const allocator_type &__a) โ€” templated constructor with allocator.
  • template<typename _SAlloc> basic_istringstream (const basic_string< _CharT, _Traits, _SAlloc > &__str, ios_base::openmode __mode, const allocator_type &__a) โ€” templated constructor with mode and allocator.
  • template<typename _SAlloc> basic_istringstream (const basic_string< _CharT, _Traits, _SAlloc > &__str, ios_base::openmode __mode=ios_base::in) โ€” templated constructor, mode defaults to ios_base::in.
  • basic_istringstream (ios_base::openmode __mode) โ€” Starts with an empty string buffer.
  • basic_istringstream (ios_base::openmode __mode, const allocator_type &__a) โ€” openmode plus allocator constructor.
  • ~basic_istringstream () โ€” The destructor does nothing. iconic, honestly.
  • template<typename _ValueT> basic_istream< _CharT, _Traits > & _M_extract (_ValueT &__v) โ€” internal extract helper.
  • const locale & _M_getloc () const โ€” Locale access.
  • void _M_setstate (iostate __state) โ€” internal state setter.
  • bool bad () const โ€” Fast error checking.
  • void clear (iostate __state=goodbit) โ€” [Re]sets the error state.
  • basic_ios & copyfmt (const basic_ios &__rhs) โ€” Copies fields of __rhs into this.
  • bool eof () const โ€” Fast error checking.
  • iostate exceptions () const โ€” Throwing exceptions on errors.
  • void exceptions (iostate __except) โ€” Throwing exceptions on errors.
  • bool fail () const โ€” Fast error checking.
  • char_type fill () const โ€” Retrieves the empty character.
  • char_type fill (char_type __ch) โ€” Sets a new empty character.
  • fmtflags flags () const โ€” Access to format flags.
  • fmtflags flags (fmtflags __fmtfl) โ€” Setting new format flags all at once.
  • streamsize gcount () const โ€” Character counting.
  • basic_istream< wchar_t > & getline (char_type *__s, streamsize __n, char_type __delim) โ€” explicit specialization declaration, defined in src/istream.cc.
  • basic_istream< char > & getline (char_type *__s, streamsize __n, char_type __delim) โ€” Explicit specialization declarations, defined in src/istream.cc.
  • locale getloc () const โ€” Locale access.
  • bool good () const โ€” Fast error checking.
  • basic_istream< wchar_t > & ignore (streamsize __n) โ€” ignore overload, wchar_t flavor.
  • basic_istream< char > & ignore (streamsize __n) โ€” ignore overload, char flavor.
  • basic_istream< wchar_t > & ignore (streamsize __n, int_type __delim) โ€” ignore with delimiter, wchar_t flavor.
  • basic_istream< char > & ignore (streamsize __n, int_type __delim) โ€” ignore with delimiter, char flavor.
  • locale imbue (const locale &__loc) โ€” Moves to a new locale.
  • long & iword (int __ix) โ€” Access to integer array.
  • char narrow (char_type __c, char __dfault) const โ€” Squeezes characters.
  • basic_istringstream & operator= (basic_istringstream &&__rhs) โ€” move assignment.
  • basic_istringstream & operator= (const basic_istringstream &)=delete โ€” copy assignment is deleted.
  • __istream_type & operator>> (__streambuf_type *__sb) โ€” Extracting into another streambuf.
  • __istream_type & operator>> (void *&__p) โ€” Basic arithmetic extractors.
  • streamsize precision () const โ€” Flags access.
  • streamsize precision (streamsize __prec) โ€” Changing flags.
  • void *& pword (int __ix) โ€” Access to void pointer array.
  • basic_streambuf< _CharT, _Traits > * rdbuf (basic_streambuf< _CharT, _Traits > *__sb) โ€” Changing the underlying buffer.
  • __stringbuf_type * rdbuf () const โ€” Accessing the underlying buffer.
  • iostate rdstate () const โ€” Returns the error state of the stream buffer.
  • void register_callback (event_callback __fn, int __index) โ€” Add the callback __fn with parameter __index.
  • fmtflags setf (fmtflags __fmtfl) โ€” Setting new format flags.
  • fmtflags setf (fmtflags __fmtfl, fmtflags __mask) โ€” Setting new format flags.
  • void setstate (iostate __state) โ€” Sets additional flags in the error state.
  • __string_type str () && โ€” rvalue str access.
  • __string_type str () const & โ€” Copying out the string buffer.
  • void str (__string_type &&__s) โ€” Setting a new buffer.
  • void str (const __string_type &__s) โ€” Setting a new buffer.
  • template<__allocator_like _SAlloc> basic_string< _CharT, _Traits, _SAlloc > str (const _SAlloc &__sa) const โ€” allocator-aware str getter.
  • template<__allocator_like _SAlloc> void str (const basic_string< _CharT, _Traits, _SAlloc > &__s) โ€” allocator-aware str setter.
  • void swap (basic_istringstream &__rhs) โ€” swap, bestie.
  • basic_ostream< _CharT, _Traits > * tie () const โ€” Fetches the current tied stream.
  • basic_ostream< _CharT, _Traits > * tie (basic_ostream< _CharT, _Traits > *__tiestr) โ€” Ties this stream to an output stream.
  • void unsetf (fmtflags __mask) โ€” Clearing format flags.
  • basic_string_view< char_type, traits_type > view () const noexcept โ€” view, no cap.
  • char_type widen (char __c) const โ€” Widens characters.
  • streamsize width () const โ€” Flags access.
  • streamsize width (streamsize __wide) โ€” Changing flags.
  • __istream_type & operator>> (__istream_type &(*__pf)(__istream_type &)) โ€” Interface for manipulators.
  • __istream_type & operator>> (__ios_type &(*__pf)(__ios_type &)) โ€” Interface for manipulators.
  • __istream_type & operator>> (ios_base &(*__pf)(ios_base &)) โ€” Interface for manipulators.

๐Ÿ’… Extractors ๐Ÿ’…

All the operator>> functions (aka formatted input functions) have some common behavior. Each starts by constructing a temporary object of type std::basic_istream::sentry with the second argument (noskipws) set to false. This has several effects, concluding with the setting of a status flag; see the sentry documentation for more.

If the sentry status is good, the function tries to extract whatever data is appropriate for the type of the argument.

If an exception is thrown during extraction, ios_base::badbit will be turned on in the stream's error state (without causing an ios_base::failure to be thrown) and the original exception will be rethrown if badbit is set in the exceptions mask.
  • __istream_type & operator>> (bool &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (short &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (unsigned short &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (int &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (unsigned int &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (long &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (unsigned long &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (long long &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (unsigned long long &__n) โ€” Integer arithmetic extractors.
  • __istream_type & operator>> (float &__f) โ€” Floating point arithmetic extractors.
  • __istream_type & operator>> (double &__f) โ€” Floating point arithmetic extractors.
  • __istream_type & operator>> (long double &__f) โ€” Floating point arithmetic extractors.

๐Ÿฆ‹ Unformatted Input Functions ๐Ÿฆ‹

All the unformatted input functions have some common behavior. Each starts by constructing a temporary object of type std::basic_istream::sentry with the second argument (noskipws) set to true. This has several effects, concluding with the setting of a status flag; see the sentry documentation for more.

If the sentry status is good, the function tries to extract whatever data is appropriate for the type of the argument.

The number of characters extracted is stored for later retrieval by gcount().

If an exception is thrown during extraction, ios_base::badbit will be turned on in the stream's error state (without causing an ios_base::failure to be thrown) and the original exception will be rethrown if badbit is set in the exceptions mask.
  • int_type get () โ€” simple extraction, no cap ๐Ÿ’…
  • __istream_type & get (char_type &__c) โ€” also simple extraction, but into a char ref ๐ŸŽ€
  • __istream_type & get (char_type *__s, streamsize __n, char_type __delim) โ€” simple multiple-character extraction, with a delimiter bestie โœจ
  • __istream_type & get (char_type *__s, streamsize __n) โ€” same thing, no delimiter specified ๐Ÿฆ‹
  • __istream_type & get (__streambuf_type &__sb, char_type __delim) โ€” extraction straight into another streambuf, delimited ๐ŸŒธ
  • __istream_type & get (__streambuf_type &__sb) โ€” extraction into another streambuf, plain and simple ๐Ÿ’œ
  • __istream_type & getline (char_type *__s, streamsize __n, char_type __delim) โ€” string extraction, delimiter included ๐Ÿ”ฅ
  • __istream_type & getline (char_type *__s, streamsize __n) โ€” string extraction, default delim energy โญ
  • __istream_type & ignore (streamsize __n, int_type __delim) โ€” discarding characters, so iconic ๐Ÿ—‘๏ธ
  • __istream_type & ignore (streamsize __n) โ€” simple extraction vibes ๐Ÿ˜Œ
  • __istream_type & ignore () โ€” simple extraction vibes, again ๐Ÿซถ
  • __istream_type & ignore (streamsize __n, char __delim) โ€” simple extraction vibes, char edition ๐Ÿ“
  • int_type peek () โ€” looking ahead in the stream, no touching, just looking ๐Ÿ‘€
  • __istream_type & read (char_type *__s, streamsize __n) โ€” extraction without delimiters, she does NOT stop for anyone ๐Ÿ’€
  • streamsize readsome (char_type *__s, streamsize __n) โ€” extraction until the buffer is exhausted, but no more. boundaries, queen ๐Ÿ‘‘
  • __istream_type & putback (char_type __c) โ€” unextracting a single character, rewinding like it never happened ๐Ÿ™ˆ
  • __istream_type & unget () โ€” unextracting the previous character, reverse uno ๐Ÿงš
  • int sync () โ€” synchronizing the stream buffer โšก
  • pos_type tellg () โ€” getting the current read position, where are we bestie ๐Ÿ“
  • __istream_type & seekg (pos_type) โ€” changing the current read position ๐Ÿš€
  • __istream_type & seekg (off_type, ios_base::seekdir) โ€” changing the current read position, but with a direction ๐ŸŒˆ
  • operator bool () const โ€” the quick-and-easy status check โœจ
  • bool operator! () const โ€” the quick-and-easy status check, but the hater version ๐Ÿ’…

๐ŸŒŸ Static Public Member Functions ๐ŸŒŸ

  • static bool sync_with_stdio (bool __sync=true) โ€” interaction with the standard C I/O objects ๐Ÿ”—
  • static int xalloc () throw () โ€” access to unique indices ๐ŸŽŸ๏ธ

๐Ÿ’ซ Static Public Attributes ๐Ÿ’ซ

  • static const openmode __noreplace โ€” yep, it's there ๐Ÿซง
  • static const fmtflags adjustfield โ€” a mask of left|right|internal. Useful for the 2-arg form of setf. ๐ŸŽฏ
  • static const openmode app โ€” seek to end before each write ๐Ÿƒโ€โ™€๏ธ
  • static const openmode ate โ€” open and seek to end immediately after opening ๐Ÿ“Œ
  • static const iostate badbit โ€” indicates a loss of integrity in an input or output sequence (such as an irrecoverable read error from a file) ๐Ÿ˜ญ
  • static const fmtflags basefield โ€” a mask of dec|oct|hex. Useful for the 2-arg form of setf. ๐Ÿงฎ
  • static const seekdir beg โ€” request a seek relative to the beginning of the stream ๐ŸŒ€
  • static const openmode binary โ€” perform input and output in binary mode (as opposed to text mode). This is probably not what you think it is; see https://gcc.gnu.org/onlinedocs/libstdc++/manual/fstreams.html#std.io.filestreams.binary โš ๏ธ
  • static const fmtflags boolalpha โ€” insert/extract bool in alphabetic rather than numeric format ๐Ÿ”ค
  • static const seekdir cur โ€” request a seek relative to the current position within the sequence ๐Ÿ“
  • static const fmtflags dec โ€” converts integer input or generates integer output in decimal base ๐Ÿ”Ÿ
  • static const seekdir end โ€” request a seek relative to the current end of the sequence ๐Ÿ
  • static const iostate eofbit โ€” indicates that an input operation reached the end of an input sequence ๐ŸŒ…
  • static const iostate failbit โ€” indicates that an input operation failed to read the expected characters, or that an output operation failed to generate the desired characters ๐Ÿ’”
  • static const fmtflags fixed โ€” generate floating-point output in fixed-point notation ๐Ÿงท
  • static const fmtflags floatfield โ€” a mask of scientific|fixed. Useful for the 2-arg form of setf. ๐ŸŽˆ
  • static const iostate goodbit โ€” indicates all is well ๐Ÿฅฐ
  • static const fmtflags hex โ€” converts integer input or generates integer output in hexadecimal base ๐Ÿ”ก
  • static const openmode in โ€” open for input. Default for ifstream and fstream. ๐Ÿ“ฅ
  • static const fmtflags internal โ€” adds fill characters at a designated internal point in certain generated output, or identical to right if no such point is designated ๐Ÿงฉ
  • static const fmtflags left โ€” adds fill characters on the right (final positions) of certain generated output. (I.e., the thing you print is flush left.). โฌ…๏ธ
  • static const fmtflags oct โ€” converts integer input or generates integer output in octal base ๐Ÿ™
  • static const openmode out โ€” open for output. Default for ofstream and fstream. ๐Ÿ“ค
  • static const fmtflags right โ€” adds fill characters on the left (initial positions) of certain generated output. (I.e., the thing you print is flush right.). โžก๏ธ
  • static const fmtflags scientific โ€” generates floating-point output in scientific notation ๐Ÿ”ฌ
  • static const fmtflags showbase โ€” generates a prefix indicating the numeric base of generated integer output ๐Ÿท๏ธ
  • static const fmtflags showpoint โ€” generates a decimal-point character unconditionally in generated floating-point output ๐ŸŽ€
  • static const fmtflags showpos โ€” generates a + sign in non-negative generated numeric output โž•
  • static const fmtflags skipws โ€” skips leading white space before certain input operations ๐Ÿซฅ
  • static const openmode trunc โ€” truncate an existing stream when opening. Default for ofstream. โœ‚๏ธ
  • static const fmtflags unitbuf โ€” flushes output after each output operation ๐Ÿšฝ
  • static const fmtflags uppercase โ€” replaces certain lowercase letters with their uppercase equivalents in generated output ๐Ÿ” 

๐Ÿ›ก๏ธ Protected Types ๐Ÿ›ก๏ธ

  • enum { _S_local_word_size } โ€” the local word size, protected bestie ๐Ÿซฃ

๐Ÿงธ Protected Member Functions ๐Ÿงธ

  • void _M_cache_locale (const locale &__loc) ๐Ÿ—‚๏ธ
  • void _M_call_callbacks (event __ev) throw () ๐Ÿ“ž
  • void _M_dispose_callbacks (void) throw () ๐Ÿ—‘๏ธ
  • template<typename _ValueT> __istream_type & _M_extract (_ValueT &__v) ๐Ÿงฒ
  • _Words & _M_grow_words (int __index, bool __iword) ๐ŸŒฑ
  • void _M_init () throw () ๐ŸŒŸ
  • void _M_move (ios_base &) noexcept ๐Ÿšš
  • void _M_swap (ios_base &__rhs) noexcept ๐Ÿ”„
  • void init (basic_streambuf< _CharT, _Traits > *__sb) โ€” all setup is performed here ๐Ÿ› ๏ธ
  • void move (basic_ios &&__rhs) ๐Ÿƒ
  • void move (basic_ios &__rhs) ๐Ÿƒโ€โ™€๏ธ
  • void set_rdbuf (basic_streambuf< _CharT, _Traits > *__sb) ๐Ÿ“Ž
  • void swap (basic_ios &__rhs) noexcept ๐Ÿ”
  • void swap (basic_istream &__rhs) ๐Ÿ”€

๐Ÿ”’ Protected Attributes ๐Ÿ”’

  • _Callback_list * _M_callbacks ๐Ÿ“‹
  • const __ctype_type * _M_ctype ๐Ÿ”ค
  • iostate _M_exception ๐Ÿšจ
  • char_type _M_fill ๐Ÿงด
  • bool _M_fill_init โœ…
  • fmtflags _M_flags ๐Ÿšฉ
  • streamsize _M_gcount ๐Ÿ”ข
  • locale _M_ios_locale ๐ŸŒ
  • _Words _M_local_word [_S_local_word_size] ๐Ÿ“š
  • const __num_get_type * _M_num_get ๐Ÿ”ฝ
  • const __num_put_type * _M_num_put ๐Ÿ”ผ
  • streamsize _M_precision ๐ŸŽฏ
  • basic_streambuf< _CharT, _Traits > * _M_streambuf ๐Ÿงบ
  • iostate _M_streambuf_state ๐Ÿ“Š
  • basic_ostream< _CharT, _Traits > * _M_tie ๐ŸŽฝ
  • streamsize _M_width ๐Ÿ“
  • _Words * _M_word ๐Ÿ“–
  • int _M_word_size ๐Ÿ”ข
  • _Words _M_word_zero 0๏ธโƒฃ

๐ŸŒธ Detailed Description ๐ŸŒธ

template<typename _CharT, typename _Traits, typename _Alloc>
    class std::basic_istringstream< _CharT, _Traits, _Alloc >

"Controlling input for std::string." periodt ๐Ÿ’–

โœจ Template Parameters โœจ

  • _CharT โ€” type of character stream ๐Ÿ”ค
  • _Traits โ€” traits for character type, defaults to char_traits<_CharT>. ๐Ÿงฌ
  • _Alloc โ€” allocator type, defaults to allocator<_CharT>. ๐Ÿงบ

This class supports reading from objects of type std::basic_string, using the inherited functions from std::basic_istream. To control the associated sequence, an instance of std::basic_stringbuf is used, which this page refers to as sb. no cap ๐Ÿซถ


๐Ÿ’– Member Typedef Documentation ๐Ÿ’–

template<typename _CharT, typename _Traits> typedef num_put<_CharT, ostreambuf_iterator<_CharT, _Traits> > std::basic_ios< _CharT, _Traits >::__num_put_type [inherited]

These are non-standard types ๐Ÿซฃโœจ

typedef void(* std::ios_base::event_callback) (event __e, ios_base &__b, int __i) [inherited]

The type of an event callback function ๐Ÿ“ฃ

Parameters

  • __e โ€” one of the members of the event enum. ๐ŸŽช
  • __b โ€” reference to the ios_base object. ๐Ÿ“ฆ
  • __i โ€” the integer provided when the callback was registered. ๐Ÿ”ข

Event callbacks are user defined functions that get called during several ios_base and basic_ios functions, specifically imbue(), copyfmt(), and ~ios(). the way they just show up ๐Ÿ˜ญ

typedef _Ios_Fmtflags std::ios_base::fmtflags [inherited]

This is a bitmask type. _Ios_Fmtflags is implementation-defined, but it is valid to perform bitwise operations on these values and expect the Right Thing to happen. Defined objects of type fmtflags are:

  • boolalpha
  • dec
  • fixed
  • hex
  • internal
  • left
  • oct
  • right
  • scientific
  • showbase
  • showpoint
  • showpos
  • skipws
  • unitbuf
  • uppercase
  • adjustfield
  • basefield
  • floatfield

typedef _Ios_Iostate std::ios_base::iostate [inherited]

This is a bitmask type. _Ios_Iostate is implementation-defined, but it is valid to perform bitwise operations on these values and expect the Right Thing to happen. Defined objects of type iostate are:

  • badbit
  • eofbit
  • failbit
  • goodbit

typedef _Ios_Openmode std::ios_base::openmode [inherited]

This is a bitmask type. _Ios_Openmode is implementation-defined, but it is valid to perform bitwise operations on these values and expect the Right Thing to happen. Defined objects of type openmode are:

  • app
  • ate
  • binary
  • in
  • out
  • trunc

typedef _Ios_Seekdir std::ios_base::seekdir [inherited]

This is an enumerated type. _Ios_Seekdir is implementation-defined. Defined values of type seekdir are:

  • beg
  • cur, equivalent to SEEK_CUR in the C standard library. ๐ŸŒ€
  • end, equivalent to SEEK_END in the C standard library. ๐Ÿ

๐Ÿฆ‹ Member Enumeration Documentation ๐Ÿฆ‹

enum std::ios_base::event [inherited]

The set of events that may be passed to an event callback. erase_event is used during ~ios() and copyfmt(). imbue_event is used during imbue(). copyfmt_event is used during copyfmt(). iconic behavior tbh ๐Ÿ’…

๐ŸŒธ Constructor & Destructor Documentation ๐ŸŒธ

bestie it's constructors time, let's GO ๐ŸŽ€


โœจ basic_istringstream() โ€” the default one, no cap โœจ

template<typename _CharT, typename _Traits, typename _Alloc>
    std::basic_istringstream< _CharT, _Traits, _Alloc >::basic_istringstream () [inline]

Default constructor, and it kicks things off with a totally empty string buffer. It initializes sb using in, and passes &sb to the base class initializer. Does not allocate any buffer. ๐Ÿ’…

That's a lie. We initialize the base class with NULL, because the string class does its own memory management. ๐Ÿ˜ญ iconic honestly

โœจ basic_istringstream(ios_base::openmode __mode) โ€” pick your mode โœจ

template<typename _CharT, typename _Traits, typename _Alloc>
    std::basic_istringstream< _CharT, _Traits, _Alloc >::basic_istringstream
    (ios_base::openmode __mode) [inline],  [explicit]

Also starts with an empty string buffer, but you get to say how it behaves ๐Ÿฆ‹

Parameters

  • __mode โ€” whether the buffer can read, or write, or both.

ios_base::in is automatically included in __mode. Periodt, you don't get a say.

Initializes sb using __mode|in, and passes &sb to the base class initializer. Does not allocate any buffer.

That's a lie. We initialize the base class with NULL, because the string class does its own memory management. ๐Ÿ’€ same energy as before

โœจ basic_istringstream(const __string_type & __str, ios_base::openmode __mode = ios_base::in) โ€” bring your own string โœจ

template<typename _CharT, typename _Traits, typename _Alloc>
    std::basic_istringstream< _CharT, _Traits, _Alloc >::basic_istringstream
    (const __string_type & __str, ios_base::openmode __mode = ios_base::in)
    [inline],  [explicit]

Now THIS one starts with an existing string buffer. main character energy ๐ŸŒŸ

Parameters

  • __str โ€” a string to copy as a starting buffer.
  • __mode โ€” whether the buffer can read, or write, or both.

ios_base::in is automatically included in mode. (yes, mode โ€” that's what the docs say, we don't make the rules ๐Ÿ™ˆ)

Initializes sb using str and mode|in, and passes &sb to the base class initializer.

That's a lie. We initialize the base class with NULL, because the string class does its own memory management. ๐Ÿ“ the trio of lies is complete

โœจ ~basic_istringstream() โ€” the destructor, she does nothing โœจ

template<typename _CharT, typename _Traits, typename _Alloc>
    std::basic_istringstream< _CharT, _Traits, _Alloc
    >::~basic_istringstream () [inline]

The destructor does nothing. Zero. Nada. The buffer is deallocated by the stringbuf object, not the formatting stream. she's just here for the vibes ๐Ÿ˜Œ


๐Ÿ’– Member Function Documentation ๐Ÿ’–

okay this is the big one, buckle up bestie, we're going through every single function fr fr ๐Ÿงš


๐ŸŒˆ std::ios_base::_M_getloc() โ€” locale access ๐ŸŒˆ

const locale & std::ios_base::_M_getloc () const [inline],  [inherited]

Returns

  • A reference to the current locale.

Like getloc above, but returns a reference instead of generating a copy. lowkey efficient of her โœจ

Referenced by:

  • std::money_get< _CharT, _InIter >::do_get()
  • std::num_get< _CharT, _InIter >::do_get()
  • std::time_get< _CharT, _InIter >::do_get()
  • std::time_get< _CharT, _InIter >::do_get_date()
  • std::time_get< _CharT, _InIter >::do_get_monthname()
  • std::time_get< _CharT, _InIter >::do_get_time()
  • std::time_get< _CharT, _InIter >::do_get_weekday()
  • std::time_get< _CharT, _InIter >::do_get_year()
  • std::num_put< _CharT, _OutIter >::do_put()
  • std::time_put< _CharT, _OutIter >::do_put()
  • std::time_get< _CharT, _InIter >::get()
  • and std::time_put< _CharT, _OutIter >::put()

๐ŸŒˆ bad() โ€” fast error checking ๐ŸŒˆ

template<typename _CharT, typename _Traits> bool std::basic_ios< _CharT,
    _Traits >::bad () const [inline],  [nodiscard],  [inherited]

Fast error checking, she's quick ๐Ÿ’จ

Returns

  • True if the badbit is set.

Note that other iostate flags may also be set. so like, don't assume it's only badbit, ok? ๐Ÿ‘€

Referenced by: std::basic_ostream< _CharT, _Traits >::sentry::sentry().


๐ŸŒˆ clear(iostate __state = goodbit) โ€” [Re]sets the error state ๐ŸŒˆ

template<typename _CharT, typename _Traits> void std::basic_ios< _CharT,
    _Traits >::clear (iostate __state = goodbit) [inherited]

[Re]sets the error state. the brackets are doing a lot of work there and I respect it ๐Ÿ’…

Parameters

  • __state โ€” the new state flag(s) to set.

See std::ios_base::iostate for the possible bit values. Most users will not need to pass an argument. (if that's you, you're valid ๐Ÿซถ)

References: std::ios_base::badbit, exceptions(), rdbuf(), and rdstate().

Referenced by:

  • std::basic_ios< char_type, traits_type >::exceptions()
  • std::basic_fstream< char >::open()
  • std::basic_fstream< char >::open()
  • std::basic_ifstream< char >::open()
  • std::basic_ifstream< char >::open()
  • std::basic_ofstream< char >::open()
  • std::basic_ofstream< char >::open()
  • std::__detail::operator>>()
  • std::basic_istream< _CharT, _Traits >::putback()
  • rdbuf()
  • std::basic_istream< _CharT, _Traits >::seekg()
  • std::basic_istream< _CharT, _Traits >::seekg()
  • std::basic_ios< char_type, traits_type >::setstate()
  • and std::basic_istream< _CharT, _Traits >::unget()

๐ŸŒˆ copyfmt() โ€” copies fields of __rhs into this ๐ŸŒˆ

template<typename _CharT, typename _Traits> basic_ios< _CharT, _Traits > &
    std::basic_ios< _CharT, _Traits >::copyfmt (const basic_ios< _CharT,
    _Traits > & __rhs) [inherited]

Copies fields of __rhs into this. it's giving "becoming your friend" ๐ŸŒธ

Parameters

  • __rhs โ€” the source values for the copies.

Returns

  • Reference to this object.

All fields of __rhs are copied into this object except that rdbuf() and rdstate() remain unchanged. All values in the pword and iword arrays are copied. Before copying, each callback is invoked with erase_event. After copying, each (new) callback is invoked with copyfmt_event. The final step is to copy exceptions(). the order MATTERS bestie, don't skip steps ๐Ÿ”ฅ

References: basic_ios(), std::__addressof(), exceptions(), fill(), std::ios_base::flags(), std::ios_base::getloc(), std::ios_base::precision(), tie(), std::tie(), and std::ios_base::width().


๐ŸŒˆ eof() โ€” fast error checking again ๐ŸŒˆ

template<typename _CharT, typename _Traits> bool std::basic_ios< _CharT,
    _Traits >::eof () const [inline],  [nodiscard],  [inherited]

Fast error checking. โšก

Returns

  • True if the eofbit is set.

Note that other iostate flags may also be set. same disclaimer, every time, iconic consistency ๐Ÿ’€


๐ŸŒˆ exceptions() const โ€” the getter ๐ŸŒˆ

template<typename _CharT, typename _Traits> iostate std::basic_ios< _CharT,
    _Traits >::exceptions () const [inline],  [nodiscard],  [inherited]

Throwing exceptions on errors. ๐Ÿ˜ค

Returns

  • The current exceptions mask.

This changes nothing in the stream. See the one-argument version of exceptions(iostate) for the meaning of the return value.

Referenced by: clear(), and copyfmt().


๐ŸŒˆ exceptions(iostate __except) โ€” the setter, and she's dramatic ๐ŸŒˆ

template<typename _CharT, typename _Traits> void std::basic_ios< _CharT,
    _Traits >::exceptions (iostate __except) [inline],  [inherited]

Throwing exceptions on errors.

Parameters

  • __except โ€” the new exceptions mask.

By default, error flags are set silently. You can set an exceptions mask for each stream; if a bit in the mask becomes set in the error flags, then an exception of type std::ios_base::failure is thrown. ๐Ÿ”ฅ

If the error flag is already set when the exceptions mask is added, the exception is immediately thrown. Try running the following under GCC 3.1 or later:

#include <iostream>
#include <fstream>
#include <exception>

int main()
{
    std::set_terminate (__gnu_cxx::__verbose_terminate_handler);

    std::ifstream f ("/etc/motd");

    std::cerr << "Setting badbit\n";
    f.setstate (std::ios_base::badbit);

    std::cerr << "Setting exception mask\n";
    f.exceptions (std::ios_base::badbit);
}
bestie run this and watch the chaos unfold, it's giving cinema ๐Ÿ˜ญ

๐ŸŒˆ fail() โ€” fast error checking, the remix ๐ŸŒˆ

template<typename _CharT, typename _Traits> bool std::basic_ios< _CharT,
    _Traits >::fail () const [inline],  [nodiscard],  [inherited]

Fast error checking. โšกโšก

Returns

  • True if either the badbit or the failbit is set.

Checking the badbit in fail() is historical practice. Note that other iostate flags may also be set. yes we know, we've heard it before, but it's true every time ๐Ÿซถ

Referenced by:

  • std::basic_ios< char_type, traits_type >::operator bool()
  • std::basic_ios< char_type, traits_type >::operator!()
  • std::basic_istream< _CharT, _Traits >::seekg()
  • std::basic_istream< _CharT, _Traits >::seekg()
  • std::basic_ostream< _CharT, _Traits >::seekp()
  • std::basic_ostream< _CharT, _Traits >::seekp()
  • std::basic_istream< _CharT, _Traits >::tellg()
  • and std::basic_ostream< _CharT, _Traits >::tellp()

๐ŸŒˆ fill() const โ€” retrieves the empty character ๐ŸŒˆ

template<typename _CharT, typename _Traits> char_type std::basic_ios<
    _CharT, _Traits >::fill () const [inline],  [nodiscard],  [inherited]

Retrieves the empty character. ๐ŸŒธ

Returns

  • The current fill character.

It defaults to a space (' ') in the current locale. the humble space, doing so much for us ๐Ÿ’…

Referenced by: copyfmt(), and std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator<<.


๐ŸŒˆ fill(char_type __ch) โ€” sets a new empty character ๐ŸŒˆ

template<typename _CharT, typename _Traits> char_type std::basic_ios<
    _CharT, _Traits >::fill (char_type __ch) [inline],  [inherited]

Sets a new empty character.

Parameters

  • __ch โ€” the new character.

Returns

  • The previous fill character.

The fill character is used to fill out space when P+ characters have been requested (e.g., via setw), Q characters are actually used, and Q<P. It defaults to a space (' ') in the current locale. math girlies rise, Q<P is a whole inequality ๐Ÿงฎโœจ


๐ŸŒˆ std::ios_base::flags() const โ€” access to format flags ๐ŸŒˆ

fmtflags std::ios_base::flags () const [inline],  [nodiscard],  [inherited]

Access to format flags.

Returns

  • The format control flags for both input and output.

Referenced by:

  • std::basic_ios< _CharT, _Traits >::copyfmt()
  • std::num_get< _CharT, _InIter >::do_get()
  • std::num_get< _CharT, _InIter >::do_get()
  • std::num_put< _CharT, _OutIter >::do_put()
  • std::num_put< _CharT, _OutIter >::do_put()
  • std::chrono::operator<<()
  • std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator<<
  • std::__detail::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::operator>>()
  • and std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator>>

๐ŸŒˆ std::ios_base::flags(fmtflags __fmtfl) โ€” setting new format flags all at once ๐ŸŒˆ

fmtflags std::ios_base::flags (fmtflags __fmtfl) [inline],  [inherited]

Setting new format flags all at once. go big or go home ๐Ÿ”ฅ

Parameters

  • __fmtfl โ€” the new flags to set.

Returns

  • The previous format control flags.

This function overwrites all the format flags with __fmtfl. not a merge, an overwrite. she does not share the spotlight ๐Ÿ’…


๐ŸŒˆ gcount() โ€” character counting ๐ŸŒˆ

template<typename _CharT, typename _Traits> streamsize std::basic_istream<
    _CharT, _Traits >::gcount () const [inline],  [inherited]

Character counting. ๐Ÿ”ข

Returns

  • The number of characters extracted by the previous unformatted input function dispatched for this stream.

๐ŸŒˆ get(void) โ€” simple extraction ๐ŸŒˆ

template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits
    >::int_type std::basic_istream< _CharT, _Traits >::get (void )
    [inherited]

Simple extraction. keep it simple, bestie โœจ

Returns

  • A character, or eof().

Tries to extract a character. If none are available, sets failbit and returns traits::eof(). ๐Ÿซ 

References: _M_gcount, std::ios_base::badbit, std::ios_base::eofbit, std::ios_base::failbit, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), and std::basic_ios< _CharT, _Traits >::setstate().

Referenced by: std::basic_istream< char_type, traits_type >::get(), and std::basic_istream< char_type, traits_type >::get().


๐ŸŒˆ get(__streambuf_type & __sb) โ€” extraction into another streambuf ๐ŸŒˆ

template<typename _CharT, typename _Traits> __istream_type &
    std::basic_istream< _CharT, _Traits >::get (__streambuf_type & __sb)
    [inline],  [inherited]

Extraction into another streambuf. ๐Ÿฆ‹

Parameters

  • __sb โ€” a streambuf in which to store data.

Returns

  • *this

Returns get(__sb,widen('\n')). that's it, that's the whole function, she's a shortcut queen ๐Ÿ’…


๐ŸŒˆ get(__streambuf_type & __sb, char_type __delim) โ€” extraction into another streambuf, now with a stop character ๐ŸŒˆ

template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits >
    & std::basic_istream< _CharT, _Traits >::get (__streambuf_type & __sb,
    char_type __delim) [inherited]

Extraction into another streambuf, but this time you get to say when to stop ๐Ÿ›‘

Parameters

  • __sb โ€” a streambuf in which to store data.
  • __delim โ€” a "stop" character.

Characters get extracted and yeeted into __sb until one of these things pops off:

  • the input sequence hits EOF ๐Ÿ’€
  • inserting into the output buffer fails (and in that case, the character that would have been inserted is not extracted โ€” she stays right where she is, bestie)
  • the next character equals __delim (and nope, that character is not extracted either)
  • an exception occurs (and in this case it is caught, so we move on gracefully ๐Ÿ’…)

If zero characters get stored, failbit is set in the stream's error state. ๐Ÿ˜ญ

References _M_gcount, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), and std::basic_streambuf< _CharT, _Traits >::sgetc().


๐Ÿ“ template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > & std::basic_istream< _CharT, _Traits >::get (char_type & __c) [inherited]

Simple extraction. One little guy. That's it. โœจ

Parameters

  • __c โ€” the character in which to store data. That's where she goes.

Returns

*this

Tries to extract a character and store it in __c. If none are available, it sets failbit and returns traits::eof(). Iconic sad-girl behavior, but that's the spec.

Note โ€” This function is not overloaded on signed char and unsigned char. Noted, no cap.

References _M_gcount, std::ios_base::badbit, std::ios_base::eofbit, std::ios_base::failbit, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), and std::basic_ios< _CharT, _Traits >::setstate().


๐ŸŒธ template<typename _CharT, typename _Traits> __istream_type & std::basic_istream< _CharT, _Traits >::get (char_type * __s, streamsize __n) [inline], [inherited]

Simple multiple-character extraction. Glow-up from the single-char version. ๐Ÿ’–

Parameters

  • __s โ€” pointer to an array.
  • __n โ€” maximum number of characters to store in s.

Returns

*this

Returns get(__s,__n,widen('\n')). She's literally just forwarding the call, and honestly? Relatable.


๐Ÿฆ‹ template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > & std::basic_istream< _CharT, _Traits >::get (char_type * __s, streamsize __n, char_type __delim) [inherited]

Simple multiple-character extraction, but make it deluxe.

Parameters

  • __s โ€” pointer to an array.
  • __n โ€” maximum number of characters to store in __s.
  • __delim โ€” a "stop" character.

Returns

*this

Characters are extracted and stored into __s until one of the following happens:

  • __n-1 characters are stored
  • the input sequence reaches EOF
  • the next character equals __delim, in which case the character is not extracted

If no characters are stored, failbit is set in the stream's error state. ๐Ÿ˜”

In any case, a null character is stored into the next location in the array. Periodt.

Note โ€” This function is not overloaded on signed char and unsigned char.

References _M_gcount, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), and std::basic_streambuf< _CharT, _Traits >::sgetc().


๐ŸŽ€ template<typename _CharT, typename _Traits> __istream_type & std::basic_istream< _CharT, _Traits >::getline (char_type * __s, streamsize __n) [inline], [inherited]

String extraction. The main character of every while (std::getline(...)) loop ever. ๐Ÿ‘‘

Parameters

  • __s โ€” a character array in which to store the data.
  • __n โ€” maximum number of characters to extract.

Returns

*this

Returns getline(__s,__n,widen('\n')).


๐Ÿ’œ basic_istream< char > & std::basic_istream< char >::getline (char_type * __s, streamsize __n, char_type __delim) [inherited]

Explicit specialization declarations, defined in src/istream.cc.

Yes bestie, the real implementation lives in a .cc file. The header was just the trailer.


โœจ template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > & std::basic_istream< _CharT, _Traits >::getline (char_type * __s, streamsize __n, char_type __delim) [inherited]

String extraction. The real one. Let's get into it.

Parameters

  • __s โ€” a character array in which to store the data.
  • __n โ€” maximum number of characters to extract.
  • __delim โ€” a "stop" character.

Returns

*this

Extracts and stores characters into __s until one of the following happens. Note that these criteria are required to be tested in the order listed here, to allow an input line to exactly fill the __s array without setting failbit. The order is not a vibe, it's a requirement. ๐Ÿซถ

  1. the input sequence reaches end-of-file, in which case eofbit is set in the stream error state
  2. the next character equals __delim, in which case the character is extracted (and therefore counted in gcount()) but not stored
  3. __n-1 characters are stored, in which case failbit is set in the stream error state

If no characters are extracted, failbit is set. (An empty line of input should therefore not cause failbit to be set.) ๐Ÿ™ˆ

In any case, a null character is stored in the next location in the array.

Referenced by std::basic_istream< char_type, traits_type >::getline().


๐ŸŒˆ locale std::ios_base::getloc () const [inline], [nodiscard], [inherited]

Locale access. The [nodiscard] is watching you โ€” do not ignore her return value.

Returns

A copy of the current locale.

If imbue(loc) has previously been called, then this function returns loc. Otherwise, it returns a copy of std::locale(), the global C++ locale.

Referenced by std::basic_ios< _CharT, _Traits >::copyfmt(), std::money_put< _CharT, _OutIter >::do_put(), std::basic_ios< _CharT, _Traits >::imbue(), std::chrono::operator<<(), std::operator>>(), std::operator>>(), and std::ws().


๐Ÿ’– template<typename _CharT, typename _Traits> bool std::basic_ios< _CharT, _Traits >::good () const [inline], [nodiscard], [inherited]

Fast error checking. The vibe check function. ๐Ÿ’…

Returns

True if no error flags are set.

A wrapper around rdstate.

Referenced by std::basic_istream< _CharT, _Traits >::sentry::sentry(), std::basic_ostream< _CharT, _Traits >::sentry::sentry(), and std::__detail::operator>>().


๐Ÿงš template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > & std::basic_istream< _CharT, _Traits >::ignore (void ) [inherited]

Simple extraction. Ignore her, she's busy ignoring characters.

Returns

A character, or eof().

Tries to extract a character. If none are available, sets failbit and returns traits::eof().

References _M_gcount, std::ios_base::eofbit, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), and std::basic_streambuf< _CharT, _Traits >::sbumpc().

Referenced by std::basic_istream< char_type, traits_type >::ignore().


๐Ÿ“ template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > & std::basic_istream< _CharT, _Traits >::ignore (streamsize __n) [inherited]

Simple extraction. Same energy, new argument. โœจ

Returns

A character, or eof().

Tries to extract a character. If none are available, sets failbit and returns traits::eof().

References _M_gcount, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), and std::basic_streambuf< _CharT, _Traits >::sgetc().


๐ŸŽ€ template<typename _CharT, typename _Traits> __istream_type & std::basic_istream< _CharT, _Traits >::ignore (streamsize __n, char __delim) [inline], [inherited]

Simple extraction. Yes, the docs really do repeat this three times. We're keeping it fr fr.

Returns

A character, or eof().

Tries to extract a character. If none are available, sets failbit and returns traits::eof().


๐Ÿ’œ template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > & std::basic_istream< _CharT, _Traits >::ignore (streamsize __n, int_type __delim) [inherited]

Discarding characters. The actual ignore. ๐Ÿ—‘๏ธ

Parameters

  • __n โ€” number of characters to discard.
  • __delim โ€” a "stop" character.

Returns

*this

Extracts characters and throws them away until one of the following happens:

  • if __n != std::numeric_limits<int>::max(), __n characters are extracted
  • the input sequence reaches end-of-file
  • the next character equals __delim (in this case, the character is extracted); note that this condition will never occur if __delim equals traits::eof()
NB: Provide four overloads, instead of the single function (with defaults) mandated by the Standard: this leads to a better performing implementation, while still conforming to the Standard. She's doing extra credit and still following the syllabus. Queen behavior. ๐Ÿ‘‘

References _M_gcount, and std::ios_base::goodbit.


๐ŸŒธ template<typename _CharT, typename _Traits> locale std::basic_ios< _CharT, _Traits >::imbue (const locale & __loc) [inherited]

Moves to a new locale. Locale glow-up. ๐ŸŒ

Parameters

  • __loc โ€” the new locale.

Returns

The previous locale.

Calls ios_base::imbue(loc), and if a stream buffer is associated with this stream, calls that buffer's pubimbue(loc).

Additional l10n notes are at https://gcc.gnu.org/onlinedocs/libstdc++/manual/localization.html

References std::ios_base::getloc(), std::ios_base::imbue(), and rdbuf().

Referenced by std::chrono::operator<<().


๐Ÿฆ‹ template<typename _CharT, typename _Traits> void std::basic_ios< _CharT, _Traits >::init (basic_streambuf< _CharT, _Traits > * __sb) [protected], [inherited]

All setup is performed here. This is called from the public constructor. It is not virtual and cannot be redefined. Don't even try it bestie, she's locked. ๐Ÿ”’

Referenced by std::basic_fstream< char >::basic_fstream(), std::basic_fstream< char >::basic_fstream(), std::basic_fstream< char >::basic_fstream(), std::basic_ifstream< char >::basic_ifstream(), std::basic_ifstream< char >::basic_ifstream(), std::basic_ifstream< char >::basic_ifstream(), std::basic_ios< char_type, traits_type >::basic_ios(), std::basic_istream< char_type, traits_type >::basic_istream(), std::basic_istringstream< char >::basic_istringstream(), std::basic_istringstream< char >::basic_istringstream(), std::basic_istringstream< char >::basic_istringstream(), std::basic_ofstream< char >::basic_ofstream(), std::basic_ofstream< char >::basic_ofstream(), std::basic_ofstream< char >::basic_ofstream(), std::basic_ostream< char_type, traits_type >::basic_ostream(), std::basic_ostringstream< char >::basic_ostringstream(), std::basic_ostringstream< char >::basic_ostringstream(), std::basic_ostringstream< char >::basic_ostringstream(), std::basic_stringstream< char >::basic_stringstream(), std::basic_stringstream< char >::basic_stringstream(), and std::basic_stringstream< char >::basic_stringstream().

That list? Everyone pulls up to init. It's giving main character energy for a protected function, honestly.


๐ŸŽ€ long & std::ios_base::iword (int __ix) [inline], [inherited]

Access to integer array. Your own lil' scratch space.

Parameters

  • __ix โ€” index into the array.

Returns

A reference to an integer associated with the index.

The iword function provides access to an array of integers that can be used for any purpose. The array grows as required to hold the supplied index. All integers in the array are initialized to 0.

The implementation reserves several indices. You should use xalloc to obtain an index that is safe to use. Also note that since the array can grow dynamically, it is not safe to hold onto the reference. ๐Ÿ™…โ€โ™€๏ธ Don't clutch it, bestie, she may move.

References iword().

Referenced by iword().


๐Ÿ’– template<typename _CharT, typename _Traits> char std::basic_ios< _CharT, _Traits >::narrow (char_type __c, char __dfault) const [inline], [inherited]

Squeezes characters. Compression but for character types. ๐Ÿซถ

Parameters

  • __c โ€” the character to narrow.
  • __dfault โ€” the character to narrow.

Returns

The narrowed character.

Maps a character of char_type to a character of char, if possible. โœจ

Returns the result of

std::use_facet<ctype<char_type> >(getloc()).narrow(c,dfault)

Additional l10n notes are at https://gcc.gnu.org/onlinedocs/libstdc++/manual/localization.html ๐ŸŒ


operator bool () โ€” the vibe check for your stream ๐Ÿ’…

template<typename _CharT, typename _Traits>
std::basic_ios<_CharT, _Traits>::operator bool () const

[inline], [explicit], [nodiscard], [inherited]

Bestie, this is the quick-and-easy status check. It's literally the "are you okay??" text you send at 2am. It lets you write stuff like if (!a_stream) ... and while (a_stream) ... โ€” no cap. โœจ

operator! () โ€” the other vibe check ๐Ÿฆ‹

template<typename _CharT, typename _Traits>
bool std::basic_ios<_CharT, _Traits>::operator! () const

[inline], [nodiscard], [inherited]

Again: the quick-and-easy status check. Same energy, opposite sign. Lets you write if (!a_stream) ... and while (a_stream) .... That's it, that's the whole thing. ๐Ÿ’–


๐ŸŽ€ operator>> overloads โ€” the extractor era

operator>> (__ios_type &(*__pf)(__ios_type &)) โ€” manipulator interface ๐Ÿงš

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(__ios_type& (*__pf)(__ios_type&))

[inline], [inherited]

It's the interface for manipulators. Manipulators like std::ws and std::dec use these functions in constructs like std::cin >> std::ws. Want the lore? Go look at the iomanip header. ๐Ÿ‘‘

operator>> (__istream_type &(*__pf)(__istream_type &)) โ€” manipulator interface, the sequel ๐ŸŒธ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(__istream_type& (*__pf)(__istream_type&))

[inline], [inherited]

Interface for manipulators. Manipulators such as std::ws and std::dec use these functions in constructs like std::cin >> std::ws. For more information, see the iomanip header. ๐Ÿ’…

operator>> (__streambuf_type *__sb) โ€” extracting into another streambuf ๐Ÿ’€

template<typename _CharT, typename _Traits>
basic_istream<_CharT, _Traits>&
std::basic_istream<_CharT, _Traits>::operator>>(__streambuf_type* __sb)

[inherited]

Extracting into another streambuf. Yes bestie, into a whole other streambuf, it's giving multitasking. ๐Ÿ˜ญ

Parameters

  • __sb โ€” a pointer to a streambuf.

This function behaves like one of the basic arithmetic extractors, in that it also constructs a sentry object and has the same error handling behavior.

If __sb is NULL, the stream will set failbit in its error state. Not the vibe. ๐Ÿ™ˆ

Characters are extracted from this stream and inserted into the __sb streambuf until one of the following occurs:

  • the input stream reaches end-of-file,
  • insertion into the output buffer fails (in this case, the character that would have been inserted is not extracted), or
  • an exception occurs (and in this case is caught).

If the function inserts no characters, failbit is set.

References std::ios_base::eofbit, std::ios_base::failbit, std::ios_base::goodbit, std::basic_ios<_CharT, _Traits>::rdbuf(), and std::basic_ios<_CharT, _Traits>::setstate().

operator>> (bool &__n) โ€” integer arithmetic extractors ๐Ÿ”ฅ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(bool& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. Periodt. โœจ

operator>> (double &__f) โ€” floating point arithmetic extractors ๐Ÿฆ‹

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(double& __f)

[inline], [inherited]

Floating point arithmetic extractors.

Parameters

  • __f โ€” a variable of builtin floating point type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿ“

operator>> (float &__f) โ€” floating point arithmetic extractors (yes, again) ๐ŸŒˆ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(float& __f)

[inline], [inherited]

Floating point arithmetic extractors.

Parameters

  • __f โ€” a variable of builtin floating point type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿ’œ

operator>> (int &__n) โ€” integer arithmetic extractors ๐Ÿ’–

template<typename _CharT, typename _Traits>
basic_istream<_CharT, _Traits>&
std::basic_istream<_CharT, _Traits>::operator>>(int& __n)

[inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐ŸŽ€

operator>> (ios_base &(*__pf)(ios_base &)) โ€” manipulator interface again ๐Ÿงš

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(ios_base& (*__pf)(ios_base&))

[inline], [inherited]

Interface for manipulators. Manipulators such as std::ws and std::dec use these functions in constructs like std::cin >> std::ws. For more information, see the iomanip header. ๐Ÿ‘‘

operator>> (long &__n) โ€” integer arithmetic extractors ๐ŸŒธ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(long& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿ’…

operator>> (long double &__f) โ€” floating point arithmetic extractors โœจ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(long double& __f)

[inline], [inherited]

Floating point arithmetic extractors.

Parameters

  • __f โ€” a variable of builtin floating point type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿฆ‹

operator>> (long long &__n) โ€” integer arithmetic extractors ๐Ÿ”ฅ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(long long& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐ŸŒˆ

operator>> (short &__n) โ€” integer arithmetic extractors ๐ŸŽ€

template<typename _CharT, typename _Traits>
basic_istream<_CharT, _Traits>&
std::basic_istream<_CharT, _Traits>::operator>>(short& __n)

[inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data.

References std::ios_base::badbit, std::ios_base::failbit, std::num_get<_CharT, _InIter>::get(), std::ios_base::goodbit, std::basic_ios<_CharT, _Traits>::setstate(), and std::use_facet(). ๐Ÿ’œ

operator>> (unsigned int &__n) โ€” integer arithmetic extractors ๐Ÿ’–

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(unsigned int& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿงš

operator>> (unsigned long &__n) โ€” integer arithmetic extractors ๐ŸŒธ

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(unsigned long& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. โœจ

operator>> (unsigned long long &__n) โ€” integer arithmetic extractors ๐Ÿ‘‘

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(unsigned long long& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿ’…

operator>> (unsigned short &__n) โ€” integer arithmetic extractors ๐Ÿ“

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(unsigned short& __n)

[inline], [inherited]

Integer arithmetic extractors.

Parameters

  • __n โ€” a variable of builtin integral type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐Ÿฆ‹

operator>> (void *&__p) โ€” basic arithmetic extractors ๐Ÿ’€

template<typename _CharT, typename _Traits>
__istream_type&
std::basic_istream<_CharT, _Traits>::operator>>(void*& __p)

[inline], [inherited]

Basic arithmetic extractors.

Parameters

  • __p โ€” a variable of pointer type.

Returns

  • *this if successful.

These functions use the stream's current locale (specifically, the num_get facet) to parse the input data. ๐ŸŒˆ


peek (void ) โ€” looking ahead in the stream ๐Ÿ‘€

template<typename _CharT, typename _Traits>
basic_istream<_CharT, _Traits>::int_type
std::basic_istream<_CharT, _Traits>::peek(void)

[inherited]

Looking ahead in the stream. Like peeking at the group chat before you type, bestie. ๐Ÿ™ˆ

Returns

  • The next character, or eof().

If, after constructing the sentry object, good() is false, returns traits::eof(). Otherwise reads but does not extract the next input character.

References _M_gcount, std::ios_base::goodbit, and std::basic_ios<_CharT, _Traits>::rdbuf().

precision () const โ€” flags access โœจ

streamsize std::ios_base::precision() const

[inline], [nodiscard], [inherited]

Flags access.

Returns

  • The precision to generate on certain output operations.
Be careful if you try to give a definition of precision here; see DR 189. Lowkey a trap. ๐Ÿ’€

Referenced by std::basic_ios<_CharT, _Traits>::copyfmt(), and std::chrono::operator<<().

precision (streamsize __prec) โ€” changing flags ๐ŸŽ€

streamsize std::ios_base::precision(streamsize __prec)

[inline], [inherited]

Changing flags.

Parameters

  • __prec โ€” the new precision value.

Returns

  • The previous value of precision().

putback (char_type __c) โ€” unextracting a single character ๐Ÿ˜ญ

template<typename _CharT, typename _Traits>
basic_istream<_CharT, _Traits>&
std::basic_istream<_CharT, _Traits>::putback(char_type __c)

[inherited]

Unextracting a single character. The un-eat. The anti-snack. Put it back where you found it. ๐Ÿ’…

Parameters

  • __c โ€” the character to push back into the input stream.

Returns

  • *this.

If rdbuf() is not null, calls rdbuf()->sputbackc(c).

If rdbuf() is null or if sputbackc() fails, sets badbit in the error state.

Note โ€” This function first clears eofbit. Since no characters are extracted, the next call to gcount() will return 0, as required by DR 60. Fr fr, zero. ๐Ÿซถ

References _M_gcount, std::ios_base::badbit, std::basic_ios<_CharT, _Traits>::clear(), std::ios_base::eofbit, std::ios_base::goodbit, std::basic_ios<_CharT, _Traits>::rdbuf(), std::basic_ios<_CharT, _Traits>::rdstate(), std::basic_ios<_CharT, _Traits>::setstate(), and std::basic_streambuf<_CharT, _Traits>::sputbackc().

Referenced by std::operator<<().

pword (int __ix) โ€” access to void pointer array ๐ŸŒŸ

void*& std::ios_base::pword(int __ix)

[inline], [inherited]

Access to void pointer array.

Parameters

  • __ix โ€” index into the array.

Returns

  • A reference to a void* associated with the index.

The pword function provides access to an array of pointers that can be used for any purpose. The array grows as required to hold the supplied index. All pointers in the array are initialized to 0. Iconic, honestly. ๐Ÿ’–

okay bestie, quick heads-up before we keep rolling ๐Ÿ’– โ€” the implementation reserves several indices for itself, so if you want an index that's actually safe to use, you gotta grab one with xalloc. And also, real talk: since that array can grow dynamically, it is not safe to hold onto the reference. let it go, bestie. ๐Ÿ™ˆ


๐Ÿ”„ rdbuf โ€” the setter version

template<typename _CharT, typename _Traits> basic_streambuf<_CharT, _Traits>* std::basic_ios<_CharT, _Traits>::rdbuf(basic_streambuf<_CharT, _Traits>* __sb) [inherited]

Changing the underlying buffer. glowy new buffer, who dis โœจ

Parameters

  • __sb โ€” the new stream buffer.

Returns

  • the previous stream buffer.

So basically: it associates a new buffer with the current stream, and clears the error state. two birds, one slay.

Now here's the messy part, and I need you to sit with me: due to historical accidents which the LWG refuses to correct ๐Ÿ˜ญ, the I/O library suffers from a design error โ€” this function is hidden in derived classes by overrides of the zero-argument rdbuf(), which is non-virtual for hysterical raisins. As a result, you must use explicit qualifications to access this function via any derived class. Like so:

std::fstream     foo;         // or some other derived type
std::streambuf*  p = .....;

foo.ios::rdbuf(p);            // ios == basic_ios<char>

References clear().


๐ŸŽ€ rdbuf() โ€” the getter version (istringstream edition)

template<typename _CharT, typename _Traits, typename _Alloc> __stringbuf_type* std::basic_istringstream<_CharT, _Traits, _Alloc>::rdbuf() const [inline], [nodiscard]

Accessing the underlying buffer.

Returns

  • the current basic_stringbuf buffer.

Notably, this one hides both signatures of std::basic_ios::rdbuf(). the audacity, honestly ๐Ÿซฃ


๐Ÿง  rdstate

template<typename _CharT, typename _Traits> iostate std::basic_ios<_CharT, _Traits>::rdstate() const [inline], [nodiscard], [inherited]

Returns the error state of the stream buffer.

Returns

  • a bit pattern (well, isn't everything? ๐Ÿ’…)

See std::ios_base::iostate for the possible bit values. Most users will just call one of the interpreting wrappers instead, e.g. good().

Referenced by std::basic_ios<char_type, traits_type>::bad(), clear(), std::basic_ios<char_type, traits_type>::eof(), std::basic_ios<char_type, traits_type>::fail(), std::basic_ios<char_type, traits_type>::good(), std::basic_istream<_CharT, _Traits>::putback(), std::basic_istream<_CharT, _Traits>::seekg(), std::basic_istream<_CharT, _Traits>::seekg(), std::basic_ios<char_type, traits_type>::setstate(), and std::basic_istream<_CharT, _Traits>::unget().


๐Ÿ“ฅ read

template<typename _CharT, typename _Traits> basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::read(char_type* __s, streamsize __n) [inherited]

Extraction without delimiters. no commas, no whitespace-skipping, just vibes and characters.

Parameters

  • __s โ€” a character array.
  • __n โ€” maximum number of characters to store.

Returns

  • *this

If the stream state is good(), it extracts characters and stores them into __s until one of these happens:

  • __n characters are stored
  • the input sequence reaches end-of-file, in which case the error state is set to failbit|eofbit.
Note: this function is not overloaded on signed char and unsigned char. just so you know, bestie ๐Ÿซถ

References _M_gcount, std::ios_base::badbit, std::ios_base::eofbit, std::ios_base::failbit, std::ios_base::goodbit, std::basic_ios<_CharT, _Traits>::rdbuf(), and std::basic_ios<_CharT, _Traits>::setstate().


๐Ÿฅ„ readsome

template<typename _CharT, typename _Traits> streamsize std::basic_istream<_CharT, _Traits>::readsome(char_type* __s, streamsize __n) [inherited]

Extraction until the buffer is exhausted, but no more. it's giving "eat what's on your plate, don't go back for seconds" ๐Ÿ“

Parameters

  • __s โ€” a character array.
  • __n โ€” maximum number of characters to store.

Returns

  • the number of characters extracted.

Extracts characters and stores them into __s depending on the number of characters remaining in the streambuf's buffer, rdbuf()->in_avail(), called A here:

  • if A == -1, sets eofbit and extracts no characters
  • if A == 0, extracts no characters
  • if A > 0, extracts min(A,n)

The goal here is to empty the current buffer, and to not request any more from the external input sequence controlled by the streambuf.

References _M_gcount, std::ios_base::badbit, std::ios_base::eofbit, std::ios_base::goodbit, std::min(), std::basic_ios<_CharT, _Traits>::rdbuf(), and std::basic_ios<_CharT, _Traits>::setstate().


๐Ÿ“ž register_callback

void std::ios_base::register_callback(event_callback __fn, int __index) [inherited]

Add the callback __fn with parameter __index.

Parameters

  • __fn โ€” the function to add.
  • __index โ€” the integer to pass to the function when invoked.

Registers a function as an event callback with an integer parameter that gets passed to the function when it's invoked. Multiple copies of the function are allowed. And if there are multiple callbacks? They're invoked in the order they were registered. first come, first served, periodt. ๐Ÿ’…


โช seekg (the offset + direction one)

template<typename _CharT, typename _Traits> basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::seekg(off_type __off, ios_base::seekdir __dir) [inherited]

Changing the current read position. time travel, but for your stream ๐Ÿฆ‹

Parameters

  • __off โ€” a file offset object.
  • __dir โ€” the direction in which to seek.

Returns

  • *this

If fail() is not true, it calls rdbuf()->pubseekoff(__off,__dir). If that function fails, it sets failbit.

Note: this function first clears eofbit. It does not count the number of characters extracted, if any, and therefore does not affect the next call to gcount().

References std::ios_base::badbit, std::basic_ios<_CharT, _Traits>::clear(), std::ios_base::eofbit, std::basic_ios<_CharT, _Traits>::fail(), std::ios_base::failbit, std::ios_base::goodbit, std::ios_base::in, std::basic_ios<_CharT, _Traits>::rdbuf(), std::basic_ios<_CharT, _Traits>::rdstate(), and std::basic_ios<_CharT, _Traits>::setstate().


โฉ seekg (the position one)

template<typename _CharT, typename _Traits> basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::seekg(pos_type __pos) [inherited]

Changing the current read position.

Parameters

  • __pos โ€” a file position object.

Returns

  • *this

If fail() is not true, it calls rdbuf()->pubseekpos(__pos). If that function fails, it sets failbit.

Note: again, this function first clears eofbit. It does not count the number of characters extracted, if any, and therefore does not affect the next call to gcount().

References std::ios_base::badbit, std::basic_ios<_CharT, _Traits>::clear(), std::ios_base::eofbit, std::basic_ios<_CharT, _Traits>::fail(), std::ios_base::failbit, std::ios_base::goodbit, std::ios_base::in, std::basic_ios<_CharT, _Traits>::rdbuf(), std::basic_ios<_CharT, _Traits>::rdstate(), and std::basic_ios<_CharT, _Traits>::setstate().


๐ŸŽ›๏ธ setf (one argument)

fmtflags std::ios_base::setf(fmtflags __fmtfl) [inline], [inherited]

Setting new format flags.

Parameters

  • __fmtfl โ€” additional flags to set.

Returns

  • the previous format control flags.

This function sets additional flags in format control. Flags that were previously set remain set โ€” nobody's getting un-set here.

Referenced by std::__detail::operator>>().


๐ŸŽ›๏ธ๐ŸŽ›๏ธ setf (with a mask)

fmtflags std::ios_base::setf(fmtflags __fmtfl, fmtflags __mask) [inline], [inherited]

Setting new format flags.

Parameters

  • __fmtfl โ€” additional flags to set.
  • __mask โ€” the flags mask for fmtfl.

Returns

  • the previous format control flags.

This function clears mask in the format flags, then sets fmtfl & mask. One example mask is ios_base::adjustfield. ๐Ÿ’…


๐Ÿšจ setstate

template<typename _CharT, typename _Traits> void std::basic_ios<_CharT, _Traits>::setstate(iostate __state) [inline], [inherited]

Sets additional flags in the error state.

Parameters

  • __state โ€” the additional state flag(s) to set.

See std::ios_base::iostate for the possible bit values.

Referenced by โ€” okay bestie, buckle up, this list is long ๐Ÿซ :

  • std::basic_ostream<_CharT, _Traits>::sentry::sentry()
  • std::basic_fstream<char>::close()
  • std::basic_ifstream<char>::close()
  • std::basic_ofstream<char>::close()
  • std::basic_ostream<_CharT, _Traits>::flush()
  • std::basic_istream<_CharT, _Traits>::get()
  • std::basic_istream<_CharT, _Traits>::get()
  • std::getline()
  • std::getline()
  • std::basic_fstream<char>::open()
  • std::basic_fstream<char>::open()
  • std::basic_ifstream<char>::open()
  • std::basic_ifstream<char>::open()
  • std::basic_ofstream<char>::open()
  • std::basic_ofstream<char>::open()
  • std::basic_ostream<_CharT, _Traits>::operator<<()
  • std::operator<<()
  • std::operator<<()
  • std::basic_istream<_CharT, _Traits>::operator>>()
  • std::basic_istream<_CharT, _Traits>::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::operator>>()
  • std::tr2::operator>>()
  • std::basic_ostream<_CharT, _Traits>::put()
  • std::basic_istream<_CharT, _Traits>::putback()
  • std::basic_istream<_CharT, _Traits>::read()
  • std::basic_istream<_CharT, _Traits>::readsome()
  • std::basic_istream<_CharT, _Traits>::seekg()
  • std::basic_istream<_CharT, _Traits>::seekg()
  • std::basic_ostream<_CharT, _Traits>::seekp()
  • std::basic_ostream<_CharT, _Traits>::seekp()
  • std::basic_istream<_CharT, _Traits>::sync()
  • std::ws()

and yes, a few of those appear twice. that's the page, not me ๐Ÿ˜ญ keeping it 100% faithful.


๐Ÿ“ str() โ€” copying it out

template<typename _CharT, typename _Traits, typename _Alloc> __string_type std::basic_istringstream<_CharT, _Traits, _Alloc>::str() const & [inline], [nodiscard]

Copying out the string buffer.

Returns

  • rdbuf()->str()

๐Ÿ” str(const __string_type&) โ€” setting a new one

template<typename _CharT, typename _Traits, typename _Alloc> void std::basic_istringstream<_CharT, _Traits, _Alloc>::str(const __string_type& __s) [inline]

Setting a new buffer.

Parameters

  • __s โ€” the string to use as a new sequence.

Calls rdbuf()->str(s).


๐Ÿ”„ sync

template<typename _CharT, typename _Traits> int std::basic_istream<_CharT, _Traits>::sync(void) [inherited]

Synchronizing the stream buffer. get everyone on the same page, bestie ๐Ÿค

Returns

  • 0 on success, -1 on failure

If rdbuf() is a null pointer, it returns -1.

Otherwise, it calls rdbuf()->pubsync(), and if that returns -1, it sets badbit and returns -1.

Otherwise, it returns 0. slay.

Note: this function does not count the number of characters extracted, if any, and therefore does not affect the next call to gcount().

References std::ios_base::badbit, std::ios_base::goodbit, std::basic_streambuf<_CharT, _Traits>::pubsync(), std::basic_ios<_CharT, _Traits>::rdbuf(), and std::basic_ios<_CharT, _Traits>::setstate().


๐ŸŒ‰ sync_with_stdio

bool std::ios_base::sync_with_stdio(bool __sync = true) [static], [inherited]

Interaction with the standard C I/O objects.

Parameters

  • __sync โ€” whether to synchronize or not.

Returns

  • true if the standard streams were previously synchronized.

Important caveat, so listen up: the synchronization referred to is only that between the standard C facilities (e.g., stdout) and the standard C++ objects (e.g., cout). User-declared streams are unaffected. See https://gcc.gnu.org/onlinedocs/libstdc++/manual/fstreams.html#std.io.filestreams.binary


tellg

template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits >::pos_type
std::basic_istream< _CharT, _Traits >::tellg (void )

[inherited]

Okay bestie, this one is literally just "where am I rn?" for reading. ๐Ÿ“ It hands you the current read position.

Returns: a file position object. Simple as that.

But the deets: if fail() is not false, it returns pos_type(-1) to say "nope, failed ๐Ÿ˜ญ". Otherwise it returns rdbuf()->pubseekoff(0,cur,in).

Note ๐Ÿซถ โ€” this function does not count how many characters got extracted (if any), so it does not affect the next call to gcount(). And โ€” plot twist โ€” at variance with putback, unget and seekg, eofbit is not cleared first. She stays where she is, periodt. ๐Ÿ’…

References std::ios_base::badbit, std::ios_base::cur, std::basic_ios< _CharT, _Traits >::fail(), std::ios_base::in, and std::basic_ios< _CharT, _Traits >::rdbuf().


tie (the const one)

template<typename _CharT, typename _Traits> basic_ostream< _CharT, _Traits > *
std::basic_ios< _CharT, _Traits >::tie () const

[inline], [nodiscard], [inherited]

Fetches the current tied stream. ๐ŸŽ€

Returns: a pointer to the tied stream, or NULL if the stream isn't tied.

So here's the vibe: a stream can be tied (a.k.a. synchronized) to a second output stream. The moment this stream does any I/O, the tied stream gets flushed first. The iconic example: std::cin is tied to std::cout. ๐ŸŒธ

Referenced by std::basic_ostream< _CharT, _Traits >::sentry::sentry(), and copyfmt().


tie (the setter one)

template<typename _CharT, typename _Traits> basic_ostream< _CharT, _Traits > *
std::basic_ios< _CharT, _Traits >::tie (basic_ostream< _CharT, _Traits > * __tiestr)

[inline], [inherited]

Ties this stream to an output stream. Gluing them together fr fr. ๐Ÿซถ

Parameters:

  • __tiestr โ€” the output stream.

Returns: the previously tied output stream, or NULL if the stream wasn't tied.

This sets up a brand new tie; peep tie() for more. ๐Ÿ’–


unget

template<typename _CharT, typename _Traits> basic_istream< _CharT, _Traits > &
std::basic_istream< _CharT, _Traits >::unget (void )

[inherited]

Unextracting the previous character. Yes, you read that right โ€” she's giving it back. ๐Ÿ˜ญ

Returns: *this

If rdbuf() is not null, it calls rdbuf()->sungetc(c).

If rdbuf() is null or if sungetc() fails, it sets badbit in the error state. ๐Ÿ’€

Note ๐Ÿงš โ€” this function first clears eofbit. And since no characters are extracted, the next call to gcount() will return 0, as required by DR 60. No cap.

References _M_gcount, std::ios_base::badbit, std::basic_ios< _CharT, _Traits >::clear(), std::ios_base::eofbit, std::ios_base::goodbit, std::basic_ios< _CharT, _Traits >::rdbuf(), std::basic_ios< _CharT, _Traits >::rdstate(), and std::basic_streambuf< _CharT, _Traits >::sungetc().

Referenced by std::__detail::operator>>().


std::ios_base::unsetf

void std::ios_base::unsetf (fmtflags __mask)

[inline], [inherited]

Clearing format flags. ๐Ÿงนโœจ

Parameters:

  • __mask โ€” the flags to unset.

This function clears __mask in the format flags.


widen

template<typename _CharT, typename _Traits> char_type
std::basic_ios< _CharT, _Traits >::widen (char __c) const

[inline], [inherited]

Widens characters. She's stretching the lil guy out. ๐ŸŒˆ

Parameters:

  • __c โ€” the character to widen.

Returns: the widened character.

Maps a character of char to a character of char_type.

Returns the result of

std::use_facet<ctype<char_type> >(getloc()).widen(c)

Additional l10n notes are at https://gcc.gnu.org/onlinedocs/libstdc++/manual/localization.html

Referenced by std::endl(), std::basic_ios< char_type, traits_type >::fill(), std::basic_istream< char_type, traits_type >::get(), std::basic_istream< char_type, traits_type >::get(), std::basic_istream< char_type, traits_type >::getline(), std::getline(), std::getline(), std::operator<<(), std::operator<<(), std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator<<, and std::tr2::operator>>().


width (getter)

streamsize std::ios_base::width () const

[inline], [nodiscard], [inherited]

Flags access. ๐Ÿ‘€

Returns: the minimum field width to generate on output operations.

Minimum field width refers to the number of characters.

Referenced by std::basic_ios< _CharT, _Traits >::copyfmt(), std::num_put< _CharT, _OutIter >::do_put(), std::operator>>(), and std::operator>>().


width (setter)

streamsize std::ios_base::width (streamsize __wide)

[inline], [inherited]

Changing flags. ๐Ÿ”ง

Parameters:

  • __wide โ€” the new width value.

Returns: the previous value of width().


xalloc

int std::ios_base::xalloc ()

[static], [inherited]

Access to unique indices. ๐Ÿ”‘

Returns: an integer different from all previous calls.

This function returns a unique integer every single time it's called. It can be used for any purpose, but it's primarily intended to be a unique index for the iword and pword functions. The expectation is that an application calls xalloc in order to obtain an index in the iword and pword arrays that can be used without fear of conflict.

The implementation maintains a static variable that is incremented and returned on each invocation. xalloc is guaranteed to return an index that is safe to use in the iword and pword arrays. Periodt. ๐Ÿ’…


๐Ÿ‘‘ Member Data Documentation ๐Ÿ‘‘

_M_gcount

template<typename _CharT, typename _Traits> streamsize
std::basic_istream< _CharT, _Traits >::_M_gcount

[protected], [inherited]

The number of characters extracted in the previous unformatted function; see gcount(). ๐Ÿงฎ

Referenced by get(), get(), get(), get(), ignore(), ignore(), ignore(), peek(), putback(), read(), readsome(), and unget().


adjustfield

const fmtflags std::ios_base::adjustfield

[static], [inherited]

A mask of left|right|internal. Useful for the 2-arg form of setf. ๐Ÿ’…

Referenced by std::num_put< _CharT, _OutIter >::do_put(), std::internal(), std::left(), and std::right().


app

const openmode std::ios_base::app

[static], [inherited]

Seek to end before each write. ๐Ÿ“

Referenced by std::basic_filebuf< char_type, traits_type >::_M_set_buffer(), std::basic_filebuf< _CharT, _Traits >::overflow(), and std::basic_filebuf< _CharT, _Traits >::xsputn().


ate

const openmode std::ios_base::ate

[static], [inherited]

Open and seek to end immediately after opening. ๐Ÿƒโ€โ™€๏ธ๐Ÿ’จ

Referenced by std::basic_filebuf< _CharT, _Traits >::open().


badbit

const iostate std::ios_base::badbit

[static], [inherited]

Indicates a loss of integrity in an input or output sequence (such as an irrecoverable read error from a file). ๐Ÿ’€ This is the "everything is on fire" bit, bestie.

Referenced by std::basic_istream< _CharT, _Traits >::sentry::sentry(), std::basic_ostream< _CharT, _Traits >::sentry::~sentry(), std::basic_ios< _CharT, _Traits >::clear(), std::basic_ostream< _CharT, _Traits >::flush(), std::basic_iostream< char_type, traits_type >::get(), std::basic_istream< _CharT, _Traits >::get(), std::basic_istream< _CharT, _Traits >::get(), std::basic_iostream< char_type, traits_type >::operator<<(), std::basic_ostream< _CharT, _Traits >::operator<<(), std::basic_istream< _CharT, _Traits >::operator>>(), std::operator>>(), std::basic_ostream< _CharT, _Traits >::put(), std::basic_istream< _CharT, _Traits >::putback(), std::basic_istream< _CharT, _Traits >::read(), std::basic_istream< _CharT, char_traits< _CharT > >::read(), std::basic_istream< _CharT, _Traits >::readsome(), std::basic_istream< _CharT, _Traits >::seekg(), std::basic_istream< _CharT, _Traits >::seekg(), std::basic_istream< _CharT, _Traits >::sync(), std::basic_istream< _CharT, _Traits >::tellg(), std::basic_istream< _CharT, _Traits >::unget(), and std::ws().


basefield

const fmtflags std::ios_base::basefield

[static], [inherited]

A mask of dec|oct|hex. Useful for the 2-arg form of setf. ๐Ÿ”ข

Referenced by std::dec(), std::num_get< _CharT, _InIter >::do_get(), std::num_put< _CharT, _OutIter >::do_put(), std::hex(), and std::oct().


beg

const seekdir std::ios_base::beg

[static], [inherited]

Request a seek relative to the beginning of the stream. โช

Referenced by std::basic_filebuf< _CharT, _Traits >::seekpos().


binary

const openmode std::ios_base::binary

[static], [inherited]

Perform input and output in binary mode (as opposed to text mode). ๐Ÿฆ‹

Heads up bestie!! ๐Ÿšจ This is probably not what you think it is; see https://gcc.gnu.org/onlinedocs/libstdc++/manual/fstreams.html#std.io.filestreams.binary.

Referenced by std::basic_filebuf< _CharT, _Traits >::showmanyc().


boolalpha

const fmtflags std::ios_base::boolalpha

[static], [inherited]

Insert/extract bool in alphabetic rather than numeric format. So you get true/false instead of 1/0, iconic honestly. โœจ

Referenced by std::boolalpha(), std::num_get< _CharT, _InIter >::do_get(), std::num_put< _CharT, _OutIter >::do_put(), and std::noboolalpha().


cur

const seekdir std::ios_base::cur

[static], [inherited]

Request a seek relative to the current position within the sequence. ๐Ÿ“

Referenced by std::basic_filebuf< _CharT, _Traits >::imbue(), std::basic_filebuf< _CharT, _Traits >::overflow(), std::basic_filebuf< _CharT, _Traits >::pbackfail(), std::basic_filebuf< _CharT, _Traits >::seekoff(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::seekoff(), std::basic_istream< _CharT, _Traits >::tellg(), and std::basic_ostream< _CharT, _Traits >::tellp().


dec

const fmtflags std::ios_base::dec

[static], [inherited]

Converts integer input or generates integer output in decimal base. ๐Ÿ”Ÿ

Referenced by std::dec(), std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator<<, and std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator>>.


end

const seekdir std::ios_base::end

[static], [inherited]

Request a seek relative to the current end of the sequence. โฉ

Referenced by std::basic_filebuf< _CharT, _Traits >::open(), and std::basic_stringbuf< _CharT, _Traits, _Alloc >::seekoff().


eofbit

const iostate std::ios_base::eofbit

[static], [inherited]

Indicates that an input operation reached the end of an input sequence. ๐Ÿ That's all she wrote.

Referenced by std::num_get< _CharT, _InIter >::do_get(), std::num_get< _CharT, _InIter >::do_get(), std::num_get< _CharT, _InIter >::do_get(), std::num_get< _CharT, _InIter >::do_get(), std::time_get< _CharT, _InIter >::do_get(), std::time_get< _CharT, _InIter >::do_get_date(), std::time_get< _CharT, _InIter >::do_get_monthname(), std::time_get< _CharT, _InIter >::do_get_time(), std::time_get< _CharT, _InIter >::do_get_weekday(), std::time_get< _CharT, _InIter >::do_get_year(), std::basic_istream< _CharT, _Traits >::get(), std::basic_istream< _CharT, _Traits >::get(), std::time_get< _CharT, _InIter >::get(), std::basic_istream< _CharT, _Traits >::ignore(), std::basic_istream< _CharT, _Traits >::operator>>(), std::operator>>(), std::basic_istream< _CharT, char_traits< _CharT > >::peek(), std::basic_istream< _CharT, _Traits >::putback(), std::basic_istream< _CharT, _Traits >::read(), std::basic_istream< _CharT, _Traits >::readsome(), std::basic_istream< _CharT, _Traits >::seekg(), std::basic_istream< _CharT, _Traits >::seekg(), std::basic_istream< _CharT, char_traits< _CharT > >::seekg(), std::basic_istream< _CharT, _Traits >::unget(), std::basic_istream< _CharT, char_traits< _CharT > >::unget(), and std::ws().

okay bestie, final stretch of the inherited ios_base constants โ€” the static data members that run the whole stream flag situation. no cap, they're the foundation of everything. let's go ๐Ÿ’…โœจ

  • const iostate std::ios_base::failbit [static], [inherited] โ€” Indicates that an input operation failed to read the expected characters, or that an output operation failed to generate the desired characters.
    • Referenced by: std::basic_ostream< _CharT, _Traits >::sentry::sentry(), std::basic_fstream< char >::close(), std::basic_ifstream< char >::close(), std::basic_ofstream< char >::close(), std::num_get< _CharT, _InIter >::do_get(), std::time_get< _CharT, _InIter >::do_get_monthname(), std::time_get< _CharT, _InIter >::do_get_weekday(), std::time_get< _CharT, _InIter >::do_get_year(), std::basic_istream< _CharT, _Traits >::get() (ร—2), std::time_get< _CharT, _InIter >::get(), std::basic_fstream< char >::open() (ร—2), std::basic_ifstream< char >::open() (ร—2), std::basic_ofstream< char >::open() (ร—2), std::operator<<(), std::basic_iostream< char_type, traits_type >::operator>>(), std::basic_istream< _CharT, _Traits >::operator>>() (ร—2), std::operator>>(), std::basic_istream< _CharT, _Traits >::read(), std::basic_istream< _CharT, _Traits >::seekg() (ร—2), std::basic_ostream< _CharT, _Traits >::seekp() (ร—2).
  • const fmtflags std::ios_base::fixed [static], [inherited] โ€” Generate floating-point output in fixed-point notation.
    • Referenced by: std::fixed(), and std::hexfloat().
  • const fmtflags std::ios_base::floatfield [static], [inherited] โ€” A mask of scientific|fixed. Useful for the 2-arg form of setf.
    • Referenced by: std::defaultfloat(), std::fixed(), std::hexfloat(), and std::scientific().
  • const iostate std::ios_base::goodbit [static], [inherited] โ€” Indicates all is well.
    • Referenced by: std::basic_istream< _CharT, _Traits >::sentry::sentry(), std::num_get< _CharT, _InIter >::do_get(), std::time_get< _CharT, _InIter >::do_get(), std::time_get< _CharT, _InIter >::do_get_monthname(), std::time_get< _CharT, _InIter >::do_get_weekday(), std::time_get< _CharT, _InIter >::do_get_year(), std::basic_ostream< _CharT, _Traits >::flush(), std::basic_iostream< char_type, traits_type >::get(), std::basic_istream< _CharT, _Traits >::get() (ร—4), std::time_get< _CharT, _InIter >::get(), std::basic_istream< _CharT, _Traits >::ignore() (ร—3), std::basic_iostream< char_type, traits_type >::operator<<(), std::basic_ostream< _CharT, _Traits >::operator<<(), std::basic_iostream< char_type, traits_type >::operator>>(), std::basic_istream< _CharT, _Traits >::operator>>() (ร—2), std::operator>>(), std::basic_istream< _CharT, _Traits >::peek(), std::basic_ostream< _CharT, _Traits >::put(), std::basic_istream< _CharT, _Traits >::putback(), std::basic_istream< _CharT, _Traits >::read(), std::basic_istream< _CharT, _Traits >::readsome(), std::basic_istream< _CharT, _Traits >::seekg() (ร—2), std::basic_istream< _CharT, _Traits >::sync(), std::basic_istream< _CharT, _Traits >::unget(), and std::ws().
  • const fmtflags std::ios_base::hex [static], [inherited] โ€” Converts integer input or generates integer output in hexadecimal base.
    • Referenced by: std::num_get< _CharT, _InIter >::do_get(), std::num_put< _CharT, _OutIter >::do_put(), and std::hex().
  • const openmode std::ios_base::in [static], [inherited] โ€” Open for input. Default for ifstream and fstream.
    • Referenced by: std::basic_fstream< char >::basic_fstream() (ร—3), std::basic_ifstream< char >::basic_ifstream() (ร—3), std::basic_istringstream< char >::basic_istringstream(), std::basic_stringbuf< char >::basic_stringbuf(), std::basic_stringstream< char >::basic_stringstream(), std::basic_filebuf< char_type, traits_type >::_M_set_buffer(), std::basic_fstream< char >::open() (ร—3), std::basic_ifstream< char >::open() (ร—3), std::basic_stringbuf< _CharT, _Traits, _Alloc >::overflow(), std::basic_filebuf< _CharT, _Traits >::pbackfail(), std::basic_streambuf< char_type, traits_type >::pubseekoff(), std::basic_streambuf< char_type, traits_type >::pubseekpos(), std::basic_istream< _CharT, _Traits >::seekg() (ร—2), std::basic_streambuf< char_type, traits_type >::seekoff(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::seekoff(), std::basic_stringbuf< char >::seekoff(), std::basic_streambuf< char_type, traits_type >::seekpos(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::seekpos(), std::basic_stringbuf< char >::seekpos(), std::basic_filebuf< _CharT, _Traits >::showmanyc(), std::basic_stringbuf< char >::showmanyc(), std::basic_istream< _CharT, _Traits >::tellg(), std::basic_filebuf< _CharT, _Traits >::underflow(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::underflow(), and std::basic_filebuf< _CharT, _Traits >::xsgetn().
  • const fmtflags std::ios_base::internal [static], [inherited] โ€” Adds fill characters at a designated internal point in certain generated output, or identical to right if no such point is designated.
    • Referenced by: std::internal().
  • const fmtflags std::ios_base::left [static], [inherited] โ€” Adds fill characters on the right (final positions) of certain generated output. (I.e., the thing you print is flush left.).
    • Referenced by: std::num_put< _CharT, _OutIter >::do_put(), std::left(), and std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator<<.
  • const fmtflags std::ios_base::oct [static], [inherited] โ€” Converts integer input or generates integer output in octal base.
    • Referenced by: std::oct().
  • const openmode std::ios_base::out [static], [inherited] โ€” Open for output. Default for ofstream and fstream.
    • Referenced by: std::basic_fstream< char >::basic_fstream() (ร—3), std::basic_ofstream< char >::basic_ofstream() (ร—3), std::basic_ostringstream< char >::basic_ostringstream(), std::basic_stringbuf< char >::basic_stringbuf(), std::basic_stringstream< char >::basic_stringstream(), std::basic_filebuf< char_type, traits_type >::_M_set_buffer(), std::basic_fstream< char >::open() (ร—3), std::basic_ofstream< char >::open() (ร—3), std::basic_filebuf< _CharT, _Traits >::overflow(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::overflow(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::pbackfail(), std::basic_streambuf< char_type, traits_type >::pubseekoff(), std::basic_streambuf< char_type, traits_type >::pubseekpos(), std::basic_streambuf< char_type, traits_type >::seekoff(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::seekoff(), std::basic_stringbuf< char >::seekoff(), std::basic_ostream< _CharT, _Traits >::seekp() (ร—2), std::basic_streambuf< char_type, traits_type >::seekpos(), std::basic_stringbuf< _CharT, _Traits, _Alloc >::seekpos(), std::basic_stringbuf< char >::seekpos(), std::basic_ostream< _CharT, _Traits >::tellp(), and std::basic_filebuf< _CharT, _Traits >::xsputn().
  • const fmtflags std::ios_base::right [static], [inherited] โ€” Adds fill characters on the left (initial positions) of certain generated output. (I.e., the thing you print is flush right.).
    • Referenced by: std::right().
  • const fmtflags std::ios_base::scientific [static], [inherited] โ€” Generates floating-point output in scientific notation.
    • Referenced by: std::hexfloat(), and std::scientific().
  • const fmtflags std::ios_base::showbase [static], [inherited] โ€” Generates a prefix indicating the numeric base of generated integer output.
    • Referenced by: std::num_put< _CharT, _OutIter >::do_put(), std::noshowbase(), and std::showbase().
  • const fmtflags std::ios_base::showpoint [static], [inherited] โ€” Generates a decimal-point character unconditionally in generated floating-point output.
    • Referenced by: std::noshowpoint(), and std::showpoint().
  • const fmtflags std::ios_base::showpos [static], [inherited] โ€” Generates a + sign in non-negative generated numeric output.
    • Referenced by: std::noshowpos(), and std::showpos().
  • const fmtflags std::ios_base::skipws [static], [inherited] โ€” Skips leading white space before certain input operations.
    • Referenced by: std::noskipws(), std::__detail::operator>>(), std::philox_engine< uint_fast32_t, 32, 4, 10, 0xCD9E8D57, 0x9E3779B9, 0xD2511F53, 0xBB67AE85 >::operator>>, and std::skipws().
  • const openmode std::ios_base::trunc [static], [inherited] โ€” Truncate an existing stream when opening. Default for ofstream.
  • const fmtflags std::ios_base::unitbuf [static], [inherited] โ€” Flushes output after each output operation.
    • Referenced by: std::basic_ostream< _CharT, _Traits >::sentry::~sentry(), std::nounitbuf(), and std::unitbuf().
  • const fmtflags std::ios_base::uppercase [static], [inherited] โ€” Replaces certain lowercase letters with their uppercase equivalents in generated output.
    • Referenced by: std::num_put< _CharT, _OutIter >::do_put(), std::nouppercase(), and std::uppercase().

๐Ÿ‘‘ Author

Generated automatically by Doxygen for libstdc++ from the source code. iconic, honestly.


That's the whole page, bestie. The footer says source/version libstdc++ and the title is std::basic...s, _Alloc >(3) โ€” the date isn't in this bit, so I'm not making one up. periodt. ๐Ÿ’…๐Ÿฆ‹

๐Ÿ“ฆ where this page comes from
  • arch rolling: gcc 16.2.1+r23+gd564253eb6c8-1 ยท GPL-3.0-or-later WITH GCC-exception-3.1 AND GFDL-1.3-or-later
  • fedora 44: libstdc++-docs 16.2.1-2.fc44
  • fedora 44: libstdc++-docs 16.2.1-3.fc44 ยท GPL-3.0-or-later AND LGPL-3.0-or-later AND (GPL-3.0-or-later WITH GCC-exception-3.1) AND (GPL-3.0-or-later WITH Texinfo-exception) AND (LGPL-2.1-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GNU-compiler-exception) AND BSL-1.0 AND GFDL-1.3-or-later AND Linux-man-pages-copyleft-2-para AND SunPro AND BSD-1-Clause AND BSD-2-Clause AND BSD-2-Clause-Views AND BSD-3-Clause AND BSD-4-Clause AND BSD-Source-Code AND Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 WITH LLVM-Exception) AND ZPL-2.1 AND ISC AND LicenseRef-Fedora-Public-Domain AND HP-1986 AND curl AND Martin-Birgmeier AND HPND-Markus-Kuhn AND dtoa AND SMLNJ AND AMD-newlib AND OAR AND HPND-merchantability-variant AND HPND-Intel
  • ๐Ÿ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms