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
6090e51b
Commit
6090e51b
authored
Feb 28, 2018
by
Victor Zverovich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix compilation errors on gcc 4.6
parent
0827ec5a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
9 deletions
+10
-9
include/fmt/format.h
include/fmt/format.h
+10
-9
No files found.
include/fmt/format.h
View file @
6090e51b
...
...
@@ -2002,7 +2002,8 @@ class format_string_checker {
public:
explicit
FMT_CONSTEXPR
format_string_checker
(
basic_string_view
<
Char
>
format_str
,
ErrorHandler
eh
)
:
arg_id_
(
-
1
),
context_
(
format_str
,
eh
)
{}
:
arg_id_
(
-
1
),
context_
(
format_str
,
eh
),
parse_funcs_
{
&
parse_format_specs
<
Args
,
parse_context_type
>
...}
{}
FMT_CONSTEXPR
void
on_text
(
const
Char
*
,
const
Char
*
)
{}
...
...
@@ -2043,9 +2044,7 @@ class format_string_checker {
int
arg_id_
;
parse_context_type
context_
;
parse_func
parse_funcs_
[
NUM_ARGS
>
0
?
NUM_ARGS
:
1
]
=
{
&
parse_format_specs
<
Args
,
parse_context_type
>
...
};
parse_func
parse_funcs_
[
NUM_ARGS
>
0
?
NUM_ARGS
:
1
];
};
template
<
typename
Char
,
typename
ErrorHandler
,
typename
...
Args
>
...
...
@@ -2286,7 +2285,7 @@ class basic_writer {
const
Spec
&
spec
;
unsigned_type
abs_value
;
char
prefix
[
4
];
unsigned
prefix_size
=
0
;
unsigned
prefix_size
;
string_view
get_prefix
()
const
{
return
string_view
(
prefix
,
prefix_size
);
}
...
...
@@ -2302,7 +2301,8 @@ class basic_writer {
}
int_writer
(
basic_writer
<
Range
>
&
w
,
Int
value
,
const
Spec
&
s
)
:
writer
(
w
),
spec
(
s
),
abs_value
(
static_cast
<
unsigned_type
>
(
value
))
{
:
writer
(
w
),
spec
(
s
),
abs_value
(
static_cast
<
unsigned_type
>
(
value
)),
prefix_size
(
0
)
{
if
(
internal
::
is_negative
(
value
))
{
prefix
[
0
]
=
'-'
;
++
prefix_size
;
...
...
@@ -2609,9 +2609,9 @@ void basic_writer<Range>::write_double(T value, const format_specs &spec) {
// Check type.
struct
spec_handler
{
char_type
type
;
bool
upper
=
false
;
bool
upper
;
explicit
spec_handler
(
char_type
t
)
:
type
(
t
)
{}
explicit
spec_handler
(
char_type
t
)
:
type
(
t
)
,
upper
(
false
)
{}
void
on_general
()
{
if
(
type
==
'G'
)
...
...
@@ -2750,6 +2750,7 @@ class output_range {
sentinel
end
()
const
;
public:
typedef
OutputIt
iterator
;
typedef
T
value_type
;
explicit
output_range
(
OutputIt
it
)
:
it_
(
it
)
{}
...
...
@@ -2764,8 +2765,8 @@ class back_insert_range:
public:
typedef
typename
Container
::
value_type
value_type
;
using
base
::
base
;
back_insert_range
(
Container
&
c
)
:
base
(
std
::
back_inserter
(
c
))
{}
back_insert_range
(
typename
base
::
iterator
it
)
:
base
(
it
)
{}
};
typedef
basic_writer
<
back_insert_range
<
internal
::
buffer
>>
writer
;
...
...
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