Tweak BasebandConfiguration constructors to avoid surprise type conversions.

This commit is contained in:
Jared Boone 2015-12-10 14:40:34 -08:00
parent f369885062
commit 83bf2a9a36
2 changed files with 8 additions and 7 deletions

View file

@ -167,14 +167,19 @@ struct BasebandConfiguration {
size_t decimation_factor;
constexpr BasebandConfiguration(
int32_t mode = -1,
uint32_t sampling_rate = 0,
int32_t mode,
uint32_t sampling_rate,
size_t decimation_factor = 1
) : mode { mode },
sampling_rate { sampling_rate },
decimation_factor { decimation_factor }
{
}
constexpr BasebandConfiguration(
) : BasebandConfiguration { -1, 0, 1 }
{
}
};
class BasebandConfigurationMessage : public Message {