20 General utilities library [utilities]

20.20 Formatting [format]

20.20.6 Arguments [format.arguments]

20.20.6.3 Class template basic_Β­format_Β­args [format.args]

namespace std {
  template<class Context>
  class basic_format_args {
    size_t size_;                               // exposition only
    const basic_format_arg<Context>* data_;     // exposition only

  public:
    basic_format_args() noexcept;

    template<class... Args>
      basic_format_args(const format-arg-store<Context, Args...>& store) noexcept;

    basic_format_arg<Context> get(size_t i) const noexcept;
  };
}
An instance of basic_Β­format_Β­args provides access to formatting arguments.
basic_format_args() noexcept;
Effects: Initializes size_Β­ with 0.
template<class... Args> basic_format_args(const format-arg-store<Context, Args...>& store) noexcept;
Effects: Initializes size_Β­ with sizeof...(Args) and data_Β­ with store.args.data().
basic_format_arg<Context> get(size_t i) const noexcept;
Returns: i < size_Β­ ? data_Β­[i] : basic_Β­format_Β­arg<Context>().
Note
:
Implementations are encouraged to optimize the representation of basic_Β­format_Β­args for small number of formatting arguments by storing indices of type alternatives separately from values and packing the former.
β€” end note
 ]