Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
F
fmt
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
fmt
Commits
c92dc374
Commit
c92dc374
authored
Jul 07, 2019
by
Victor Zverovich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
typedef -> using
parent
e3f20d3e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
24 deletions
+21
-24
include/fmt/format.h
include/fmt/format.h
+21
-24
No files found.
include/fmt/format.h
View file @
c92dc374
...
...
@@ -3334,9 +3334,8 @@ inline typename buffer_context<Char>::iterator format_to(
const
Args
&
...
args
)
{
internal
::
check_format_string
<
Args
...
>
(
format_str
);
using
context
=
buffer_context
<
Char
>
;
format_arg_store
<
context
,
Args
...
>
as
{
args
...};
return
internal
::
vformat_to
(
buf
,
to_string_view
(
format_str
),
basic_format_args
<
context
>
(
as
)
);
{
make_format_args
<
context
>
(
args
...)}
);
}
template
<
typename
OutputIt
,
typename
Char
=
char
>
...
...
@@ -3351,7 +3350,7 @@ template <typename S, typename OutputIt, typename... Args,
!
internal
::
is_contiguous_back_insert_iterator
<
OutputIt
>::
value
)
>
inline
OutputIt
vformat_to
(
OutputIt
out
,
const
S
&
format_str
,
format_args_t
<
OutputIt
,
char_t
<
S
>>
args
)
{
typedef
internal
::
output_range
<
OutputIt
,
char_t
<
S
>>
range
;
using
range
=
internal
::
output_range
<
OutputIt
,
char_t
<
S
>>
;
return
vformat_to
<
arg_formatter
<
range
>>
(
range
(
out
),
to_string_view
(
format_str
),
args
);
}
...
...
@@ -3374,10 +3373,9 @@ inline OutputIt format_to(OutputIt out, const S& format_str,
internal
::
is_string
<
S
>::
value
,
""
);
internal
::
check_format_string
<
Args
...
>
(
format_str
);
typedef
format_context_t
<
OutputIt
,
char_t
<
S
>>
context
;
format_arg_store
<
context
,
Args
...
>
as
{
args
...};
using
context
=
format_context_t
<
OutputIt
,
char_t
<
S
>>
;
return
vformat_to
(
out
,
to_string_view
(
format_str
),
basic_format_args
<
context
>
(
as
)
);
{
make_format_args
<
context
>
(
args
...)}
);
}
template
<
typename
OutputIt
>
struct
format_to_n_result
{
...
...
@@ -3406,8 +3404,8 @@ template <typename OutputIt, typename Char, typename... Args,
inline
format_to_n_result
<
OutputIt
>
vformat_to_n
(
OutputIt
out
,
std
::
size_t
n
,
basic_string_view
<
Char
>
format_str
,
format_to_n_args
<
OutputIt
,
Char
>
args
)
{
typedef
internal
::
truncating_iterator
<
OutputIt
>
It
;
auto
it
=
vformat_to
(
It
(
out
,
n
),
format_str
,
args
);
auto
it
=
vformat_to
(
internal
::
truncating_iterator
<
OutputIt
>
(
out
,
n
),
format_str
,
args
);
return
{
it
.
base
(),
it
.
count
()};
}
...
...
@@ -3425,10 +3423,9 @@ inline format_to_n_result<OutputIt> format_to_n(OutputIt out, std::size_t n,
const
S
&
format_str
,
const
Args
&
...
args
)
{
internal
::
check_format_string
<
Args
...
>
(
format_str
);
using
Char
=
char_t
<
S
>
;
format_arg_store
<
format_to_n_context
<
OutputIt
,
Char
>
,
Args
...
>
as
(
args
...);
using
context
=
format_to_n_context
<
OutputIt
,
char_t
<
S
>>
;
return
vformat_to_n
(
out
,
n
,
to_string_view
(
format_str
),
format_to_n_args
<
OutputIt
,
Char
>
(
as
)
);
{
make_format_args
<
context
>
(
args
...)}
);
}
template
<
typename
Char
>
...
...
@@ -3553,8 +3550,8 @@ FMT_END_NAMESPACE
#define FMT_STRING(s) \
[] { \
struct str : fmt::compile_string { \
typedef typename std::remove_cv<std::remove_pointer<
\
typename std::decay<decltype(s)>::type>::type>::type
char_type;
\
using char_type = typename std::remove_cv<std::remove_pointer<
\
typename std::decay<decltype(s)>::type>::type>::type
;
\
FMT_CONSTEXPR operator fmt::basic_string_view<char_type>() const { \
return {s, sizeof(s) / sizeof(char_type) - 1}; \
} \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment