mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-04 23:40:04 +00:00
Avoid shadowed variables
This commit is contained in:
parent
b751b4b8a1
commit
0a438ec726
@ -31,6 +31,11 @@ All notable changes to GNSS-SDR will be documented in this file.
|
||||
- `geohash`, an
|
||||
[encoded geographic location](https://en.wikipedia.org/wiki/Geohash).
|
||||
|
||||
### Improvements in Maintainability
|
||||
|
||||
- Removed useless casts and shadowed variables, improving source code
|
||||
readability.
|
||||
|
||||
### Improvements in Portability:
|
||||
|
||||
- Updated local `cpu_features` library to v0.9.0.
|
||||
|
@ -11309,7 +11309,6 @@ void Rinex_Printer::log_rinex_obs(std::fstream& out, const Galileo_Ephemeris& ga
|
||||
it++)
|
||||
{
|
||||
lineObs.clear();
|
||||
const auto satsys_gal = satelliteSystem.find("Galileo");
|
||||
if (satsys_gal != satelliteSystem.cend())
|
||||
{
|
||||
lineObs += satsys_gal->second;
|
||||
|
@ -423,9 +423,10 @@ int Viterbi_Decoder_Sbas::parity_counter(int symbol, int length)
|
||||
|
||||
|
||||
// prev helper class
|
||||
Viterbi_Decoder_Sbas::Prev::Prev(int states, int t) : num_states(states),
|
||||
t(t),
|
||||
refcount(1)
|
||||
Viterbi_Decoder_Sbas::Prev::Prev(int states,
|
||||
int tt) : num_states(states),
|
||||
t(tt),
|
||||
refcount(1)
|
||||
{
|
||||
state = std::vector<int>(num_states);
|
||||
v_bit = std::vector<int>(num_states);
|
||||
|
@ -56,7 +56,7 @@ private:
|
||||
{
|
||||
public:
|
||||
int num_states;
|
||||
Prev(int states, int t);
|
||||
Prev(int states, int tt);
|
||||
Prev(const Prev& prev);
|
||||
Prev& operator=(const Prev& other);
|
||||
~Prev();
|
||||
|
@ -602,10 +602,10 @@ float Galileo_HAS_data::get_code_bias_m(const std::string& signal, int PRN) cons
|
||||
if (!code_bias.empty() && !targeted_system.empty())
|
||||
{
|
||||
std::vector<std::string> systems = this->get_systems_string();
|
||||
auto Nsys = systems.size();
|
||||
auto Nsys_ = systems.size();
|
||||
auto nsys_index = std::distance(systems.cbegin(), std::find(systems.cbegin(), systems.cend(), targeted_system));
|
||||
|
||||
if (static_cast<size_t>(nsys_index) < Nsys)
|
||||
if (static_cast<size_t>(nsys_index) < Nsys_)
|
||||
{
|
||||
std::vector<std::string> signals = get_signals_in_mask(static_cast<uint8_t>(nsys_index));
|
||||
auto sig_index = std::distance(signals.cbegin(), std::find(signals.cbegin(), signals.cend(), signal));
|
||||
@ -678,10 +678,10 @@ float Galileo_HAS_data::get_phase_bias_cycle(const std::string& signal, int PRN)
|
||||
if (!phase_bias.empty() && !targeted_system.empty())
|
||||
{
|
||||
std::vector<std::string> systems = this->get_systems_string();
|
||||
auto Nsys = systems.size();
|
||||
auto Nsys_ = systems.size();
|
||||
auto nsys_index = std::distance(systems.cbegin(), std::find(systems.cbegin(), systems.cend(), targeted_system));
|
||||
|
||||
if (static_cast<size_t>(nsys_index) < Nsys)
|
||||
if (static_cast<size_t>(nsys_index) < Nsys_)
|
||||
{
|
||||
std::vector<std::string> signals = get_signals_in_mask(static_cast<uint8_t>(nsys_index));
|
||||
auto sig_index = std::distance(signals.cbegin(), std::find(signals.cbegin(), signals.cend(), signal));
|
||||
|
Loading…
Reference in New Issue
Block a user