Suppress excessive warnings about deprecated Fan interfaces (#2270)

This commit is contained in:
Oxan van Leeuwen
2021-09-13 09:39:18 +02:00
committed by GitHub
parent 3aa107142b
commit e18dfdd656
6 changed files with 20 additions and 4 deletions
+2
View File
@@ -67,6 +67,8 @@ void FanStateCall::perform() const {
this->state_->state_callback_.call();
}
// This whole method is deprecated, don't warn about usage of deprecated methods inside of it.
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
FanStateCall &FanStateCall::set_speed(const char *legacy_speed) {
const auto supported_speed_count = this->state_->get_traits().supported_speed_count();
if (strcasecmp(legacy_speed, "low") == 0) {