std::basic_format_args

Header: <format>

Provides access to formatting arguments.

# Declarations

template< class Context >
class basic_format_args;

(since C++20)

using format_args = basic_format_args<std::format_context>;

(since C++20)

using wformat_args = basic_format_args<std::wformat_context>;

(since C++20)

# Notes

std::basic_format_args has reference semantics. It is the programmer’s responsibility to ensure that *this does not outlive store (which, in turn, should not outlive the arguments to std::make_format_args or std::make_wformat_args).

# Example

This section is incompleteReason: no example

# Defect reports

DRApplied toBehavior as publishedCorrect behavior
P2216R3C++20format_args_t was provided due to overparameterization of vformat_toremoved
LWG 3810C++20basic_format_args has no deduction guideadded
LWG 4106C++20basic_format_args was default-constructibledefault constructor removed

# See also