Enable and fix -Wunused-parameter warnings.

This commit is contained in:
Reece H. Dunn
2017-10-05 07:20:44 +01:00
parent dd3df1d0a8
commit 6d9bb7ef17
6 changed files with 20 additions and 0 deletions
+2
View File
@@ -277,6 +277,8 @@ dnl ================================================================
AX_CHECK_COMPILE_FLAG([-Wunused-function], [CFLAGS="-Wunused-function $CFLAGS"])
AX_CHECK_COMPILE_FLAG([-Wunused-parameter], [CFLAGS="-Wunused-parameter $CFLAGS"])
dnl ================================================================
dnl Generate output.
dnl ================================================================
+1
View File
@@ -654,6 +654,7 @@ string_decoder_getc_auto(espeak_ng_TEXT_DECODER *decoder)
static uint32_t
null_decoder_getc(espeak_ng_TEXT_DECODER *decoder)
{
(void)decoder; // unused parameter
return 0;
}
+9
View File
@@ -573,16 +573,25 @@ void MbrolaReset(void)
espeak_ng_STATUS LoadMbrolaTable(const char *mbrola_voice, const char *phtrans, int *srate)
{
(void)mbrola_voice; // unused parameter
(void)phtrans; // unused parameter
(void)srate; // unused parameter
return ENS_NOT_SUPPORTED;
}
int MbrolaGenerate(PHONEME_LIST *phoneme_list, int *n_ph, int resume)
{
(void)phoneme_list; // unused parameter
(void)n_ph; // unused parameter
(void)resume; // unused parameter
return 0;
}
int MbrolaFill(int length, int resume, int amplitude)
{
(void)length; // unused parameter
(void)resume; // unused parameter
(void)amplitude; // unused parameter
return 0;
}
+2
View File
@@ -540,6 +540,8 @@ test_espeak_set_voice_by_properties_with_invalid_language()
int
main(int argc, char **argv)
{
(void)argc; // unused parameter
char *progdir = strdup(argv[0]);
char *dir = strrchr(progdir, '/');
if (dir != NULL) *dir = 0;
+3
View File
@@ -876,6 +876,9 @@ test_peekc()
int
main(int argc, char **argv)
{
(void)argc; // unused parameter
(void)argv; // unused parameter
test_unbound_text_decoder();
test_unknown_encoding();
+3
View File
@@ -513,6 +513,9 @@ test_uts51_emoji_keycap_sequence()
int
main(int argc, char **argv)
{
(void)argc; // unused parameter
(void)argv; // unused parameter
assert(espeak_Initialize(AUDIO_OUTPUT_SYNCHRONOUS, 0, NULL, espeakINITIALIZE_DONT_EXIT) == 22050);
test_latin();