mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-25 15:21:54 +00:00
Update docs
This commit is contained in:
parent
7d28674d3a
commit
52fcef1e57
@ -59,7 +59,7 @@ Named arguments
|
|||||||
Argument lists
|
Argument lists
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
.. doxygenfunction:: fmt::make_args(const Args&...)
|
.. doxygenfunction:: fmt::make_format_args(const Args&...)
|
||||||
|
|
||||||
.. doxygenclass:: fmt::format_arg_store
|
.. doxygenclass:: fmt::format_arg_store
|
||||||
:members:
|
:members:
|
||||||
@ -197,7 +197,7 @@ allocator::
|
|||||||
inline custom_string format(custom_allocator alloc,
|
inline custom_string format(custom_allocator alloc,
|
||||||
fmt::string_view format_str,
|
fmt::string_view format_str,
|
||||||
const Args & ... args) {
|
const Args & ... args) {
|
||||||
return vformat(alloc, format_str, fmt::make_args(args...));
|
return vformat(alloc, format_str, fmt::make_format_args(args...));
|
||||||
}
|
}
|
||||||
|
|
||||||
Custom formatting of built-in types
|
Custom formatting of built-in types
|
||||||
@ -213,7 +213,7 @@ custom argument formatter class::
|
|||||||
// with the ``x`` format specifier.
|
// with the ``x`` format specifier.
|
||||||
class custom_arg_formatter : public arg_formatter {
|
class custom_arg_formatter : public arg_formatter {
|
||||||
public:
|
public:
|
||||||
custom_arg_formatter(fmt::context &ctx, fmt::format_specs &spec)
|
custom_arg_formatter(fmt::format_context &ctx, fmt::format_specs &spec)
|
||||||
: arg_formatter(ctx, spec) {}
|
: arg_formatter(ctx, spec) {}
|
||||||
|
|
||||||
using arg_formatter::operator();
|
using arg_formatter::operator();
|
||||||
@ -236,7 +236,7 @@ custom argument formatter class::
|
|||||||
template <typename ...Args>
|
template <typename ...Args>
|
||||||
inline std::string custom_format(
|
inline std::string custom_format(
|
||||||
fmt::string_view format_str, const Args &... args) {
|
fmt::string_view format_str, const Args &... args) {
|
||||||
return custom_vformat(format_str, fmt::make_args(args...));
|
return custom_vformat(format_str, fmt::make_format_args(args...));
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string s = custom_format("{:x}", -42); // s == "ffffffd6"
|
std::string s = custom_format("{:x}", -42); // s == "ffffffd6"
|
||||||
|
Loading…
Reference in New Issue
Block a user