Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Gauthier Quesnel
irritator
Commits
282c9ba4
Commit
282c9ba4
authored
May 17, 2021
by
Gauthier Quesnel
Browse files
gui: fix real conversion warnings
parent
a34b5c46
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/gui/sources.cpp
View file @
282c9ba4
...
...
@@ -98,7 +98,8 @@ generate(std::ostream& os,
}
for
(
std
::
size_t
sz
=
0
;
sz
<
size
;
++
sz
)
{
status
=
sz
*
100.0
/
static_cast
<
double
>
(
size
);
status
=
static_cast
<
double
>
(
sz
)
*
100.0
/
static_cast
<
double
>
(
size
);
if
(
!
(
os
<<
dist
(
gen
)
<<
'\n'
))
{
status
=
-
2.0
;
return
;
...
...
@@ -113,7 +114,8 @@ generate(std::ostream& os,
}
for
(
std
::
size_t
sz
=
0
;
sz
<
size
;
++
sz
)
{
status
=
sz
*
100.0
/
static_cast
<
double
>
(
size
);
status
=
static_cast
<
double
>
(
sz
)
*
100.0
/
static_cast
<
double
>
(
size
);
const
double
value
=
dist
(
gen
);
os
.
write
(
reinterpret_cast
<
const
char
*>
(
&
value
),
sizeof
(
value
));
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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