diff options
author | Marcus Müller <mmueller@gnuradio.org> | 2019-08-17 20:32:20 +0200 |
---|---|---|
committer | Marcus Müller <marcus@hostalia.de> | 2019-08-22 15:05:58 +0200 |
commit | b08d13aed2a7e7ffdee09833bb24db8ce92dce66 (patch) | |
tree | 4846eebe25b48c615cbe07d2a9f4e79d5e8ff72d /gr-digital/lib/constellation.cc | |
parent | c6cb3bbc35153a9635d69eddab0d252f7441b854 (diff) |
clang-tidy in gnuradio-runtime: use empty() instead of size()!=0
Diffstat (limited to 'gr-digital/lib/constellation.cc')
-rw-r--r-- | gr-digital/lib/constellation.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gr-digital/lib/constellation.cc b/gr-digital/lib/constellation.cc index 2734a3e83e..3caafaa992 100644 --- a/gr-digital/lib/constellation.cc +++ b/gr-digital/lib/constellation.cc @@ -69,7 +69,7 @@ constellation::constellation(std::vector<gr_complex> constell, d_constellation[i] = d_constellation[i] * d_scalefactor; } } - if (pre_diff_code.size() == 0) + if (pre_diff_code.empty()) d_apply_pre_diff_code = false; else if (pre_diff_code.size() != constsize) throw std::runtime_error( @@ -307,7 +307,7 @@ void constellation::set_soft_dec_lut(const std::vector<std::vector<float>>& soft d_lut_scale = powf(2.0, static_cast<float>(precision)); } -bool constellation::has_soft_dec_lut() { return d_soft_dec_lut.size() > 0; } +bool constellation::has_soft_dec_lut() { return !d_soft_dec_lut.empty(); } std::vector<std::vector<float>> constellation::soft_dec_lut() { return d_soft_dec_lut; } |