diff options
author | Rosen Penev <[email protected]> | 2023-01-15 13:43:27 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2023-01-15 13:43:27 -0800 |
commit | 0526ecd2f95877b167293e50ab8ce0ce614d03f4 (patch) | |
tree | ad80a5811292e87601020f6aadcb2f6ff138761d /common | |
parent | d9d445772c50e53c12ab77d97cc5f3a76839d83a (diff) |
clang-tidy cleanups (#800)
* clang-tidy: use bool literals
Found with modernize-use-bool-literals
Signed-off-by: Rosen Penev <[email protected]>
* clang-tidy: replace std::bind with lambdas
Found with modernize-avoid-bind
Signed-off-by: Rosen Penev <[email protected]>
* clang-tidy: use data() instead of pointer stuff
Found with readability-container-data-pointe
Signed-off-by: Rosen Penev <[email protected]>
* clang-tidy: use empty()
Found with readability-container-size-empty
Signed-off-by: Rosen Penev <[email protected]>
* clang-tidy: remove static in anon namespace
Found with readability-static-definition-in-anonymous-namespace
Signed-off-by: Rosen Penev <[email protected]>
* clang-tidy: remove const return
Found with readability-const-return-type
Signed-off-by: Rosen Penev <[email protected]>
Signed-off-by: Rosen Penev <[email protected]>
Diffstat (limited to 'common')
-rw-r--r-- | common/alcomplex.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/common/alcomplex.cpp b/common/alcomplex.cpp index c4ff8fd9..2e3e0a60 100644 --- a/common/alcomplex.cpp +++ b/common/alcomplex.cpp @@ -158,7 +158,7 @@ void complex_hilbert(const al::span<std::complex<double>> buffer) *bufiter *= inverse_size; ++bufiter; bufiter = std::transform(bufiter, halfiter, bufiter, - std::bind(std::multiplies<>{}, _1, 2.0*inverse_size)); + [inverse_size](auto a){ return a * (2.0 * inverse_size); }); *bufiter *= inverse_size; ++bufiter; std::fill(bufiter, buffer.end(), std::complex<double>{}); |