diff options
author | Eugene Kosov <claprix@yandex.ru> | 2021-09-21 23:49:08 +0600 |
---|---|---|
committer | Eugene Kosov <claprix@yandex.ru> | 2021-09-22 00:51:55 +0600 |
commit | 7a442a995a67688162639b8d92096fa5f628c238 (patch) | |
tree | c24c4ff775582b4f5091276c18c7e828524606ea | |
parent | f4d6d01782ad4c885f1a4041514ba58f7b7d4ad2 (diff) | |
download | mariadb-git-bb-10.2-kevgs.tar.gz |
fix gcc and clang buildbb-10.2-kevgs
after upgrading to bison (GNU Bison) 3.8.1 build is broken like this:
build_gcc/sql/sql_yacc.cc:44772:1: error: label ‘yyexhaustedlab’ defined but not used [-Werror=unused-label]
44772 | yyexhaustedlab:
| ^~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
and:
build/sql/sql_yacc.cc:44772:1: error: unused label 'yyexhaustedlab' [-Werror,-Wunused-label]
yyexhaustedlab:
^~~~~~~~~~~~~~~
1 error generated.
fixing by disabling the diagnostics for sql_yacc.yy
-rw-r--r-- | sql/sql_yacc.yy | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy index c9dbc6fa8cc..51f6f6b28e4 100644 --- a/sql/sql_yacc.yy +++ b/sql/sql_yacc.yy @@ -70,6 +70,8 @@ #ifdef _MSC_VER /* warning C4065: switch statement contains 'default' but no 'case' labels */ #pragma warning (disable : 4065) +#elif defined(__clang__) || defined(__GNUC__) +#pragma GCC diagnostic ignored "-Wunused-label" #endif int yylex(void *yylval, void *yythd); |