Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
aa77bc32
Commit
aa77bc32
authored
Oct 29, 2018
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pcm/FloatConvert: make IntegerToFloatSampleConvert::Convert() constexpr
parent
90122969
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
FloatConvert.hxx
src/pcm/FloatConvert.hxx
+1
-2
No files found.
src/pcm/FloatConvert.hxx
View file @
aa77bc32
...
...
@@ -57,8 +57,7 @@ struct IntegerToFloatSampleConvert {
static
constexpr
DV
factor
=
1.0
/
FloatToIntegerSampleConvert
<
F
,
Traits
>::
factor
;
static_assert
(
factor
>
0
,
"Wrong factor"
);
gcc_const
static
DV
Convert
(
SV
src
)
noexcept
{
static
constexpr
DV
Convert
(
SV
src
)
noexcept
{
return
DV
(
src
)
*
factor
;
}
};
...
...
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