mirror of https://github.com/ARMmbed/mbed-os.git
Add explicit cast to bool.
parent
7d9c3d1432
commit
ca68323930
|
@ -818,23 +818,23 @@ struct extended_advertising_report_event_type_t {
|
||||||
extended_advertising_report_event_type_t(uint8_t value) : value(value) { }
|
extended_advertising_report_event_type_t(uint8_t value) : value(value) { }
|
||||||
|
|
||||||
bool connectable() {
|
bool connectable() {
|
||||||
return value & (1 << 0);
|
return static_cast<bool>(value & (1 << 0));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool scannable_advertising() {
|
bool scannable_advertising() {
|
||||||
return value & (1 << 1);
|
return static_cast<bool>(value & (1 << 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool directed_advertising() {
|
bool directed_advertising() {
|
||||||
return value & (1 << 2);
|
return static_cast<bool>(value & (1 << 2));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool scan_response() {
|
bool scan_response() {
|
||||||
return value & (1 << 3);
|
return static_cast<bool>(value & (1 << 3));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool legacy_advertising() {
|
bool legacy_advertising() {
|
||||||
return value & (1 << 4);
|
return static_cast<bool>(value & (1 << 4));
|
||||||
}
|
}
|
||||||
|
|
||||||
advertising_data_status_t data_status() {
|
advertising_data_status_t data_status() {
|
||||||
|
|
Loading…
Reference in New Issue