Skip to content

Commit e9e831e

Browse files
committed
Merge branch 'feature/7' into develop
2 parents 5695bef + aa34051 commit e9e831e

2 files changed

Lines changed: 5 additions & 6 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ History of the project development
77
- [Issue #4](https://github.com/suikan4github/rpp_driver/issues/4) Add gcov support for x86 build.
88
- [Issue #5](https://github.com/suikan4github/rpp_driver/issues/5) Migrate action from hand-made to marketplace.
99
- [Issue #6](https://github.com/suikan4github/rpp_driver/issues/6) Add comment string to the assertion.
10+
- [Issue #7](https://github.com/suikan4github/rpp_driver/issues/7) Remove default clause of adau1361.cpp and use -Wswitch-enum to detect the coverage error.
1011
- [Issue #8](https://github.com/suikan4github/rpp_driver/issues/8) Remove duplicated assertions in the adau1361lower.cpp.
1112

1213
### Deprecated

src/codec/adau1361.cpp

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@
55
* Author: Seiichi "Suikan" Horie
66
*/
77

8+
// GCC/Clang : Promote the switch-enum warning to error.
9+
// MSVC : ignored.
10+
#pragma GCC diagnostic error "-Wswitch-enum"
11+
812
#include "adau1361.hpp"
913

1014
#include <assert.h>
@@ -94,9 +98,6 @@ void ::rpp_driver::Adau1361::SetGain(CodecChannel channel, float left_gain,
9498
adau1361_lower_.SetHpOutputGain(hp_output_left_gain_,
9599
hp_output_right_gain_, hp_output_mute_);
96100
break;
97-
default:
98-
assert(false);
99-
break;
100101
}
101102
CODEC_SYSLOG("Leave.")
102103
}
@@ -130,9 +131,6 @@ void ::rpp_driver::Adau1361::Mute(CodecChannel channel, bool mute) {
130131
adau1361_lower_.SetHpOutputGain(hp_output_left_gain_,
131132
hp_output_right_gain_, hp_output_mute_);
132133
break;
133-
default:
134-
assert(false);
135-
break;
136134
}
137135
CODEC_SYSLOG("Leave.")
138136
}

0 commit comments

Comments
 (0)