Iros
Loading...
Searching...
No Matches
format_args_storage.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
di/format/format_args.h
"
4
#include "
di/vocab/array/prelude.h
"
5
6
namespace
di::format
{
7
template
<
size_t
count, concepts::FormatArg Arg>
8
class
FormatArgsStorage
:
public
FormatArgs
<Arg> {
9
public
:
10
using
FormatArgs
<Arg>::operator[];
11
12
template
<concepts::SameAs<Arg>... Args>
13
requires
(
sizeof
...(Args) ==
count
)
14
constexpr
FormatArgsStorage
(Args&&... args) :
FormatArgs<Arg>
({}), m_storage { util::forward<Args>(args)... } {
15
this->
set_args
(m_storage.span());
16
}
17
18
private
:
19
Array<Arg, count> m_storage;
20
};
21
}
di::format::FormatArgsStorage::FormatArgsStorage
constexpr FormatArgsStorage(Args &&... args)
Definition
format_args_storage.h:14
di::format::FormatArgs::set_args
constexpr void set_args(Span< Arg > args)
Definition
format_args.h:16
di::format::FormatArgs::FormatArgs
constexpr FormatArgs(Span< Arg > args)
Definition
format_args.h:10
format_args.h
prelude.h
di::format
Definition
bounded_format_context.h:7
di::count
constexpr auto count
Definition
count.h:37
libs
di
include
di
format
format_args_storage.h
Generated by
1.13.0