Fix: the information returned by bison execution is not printed correctly (#764)

This commit is contained in:
BraveLz 2022-01-19 10:34:40 +08:00 committed by GitHub
parent aa8ef6a07f
commit d545b1e449
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,9 +19,10 @@ fi
# generate sql_parser
bison -v -Werror -d ../../../src/sql/parser/sql_parser_mysql_mode.y -o ../../../src/sql/parser/sql_parser_mysql_mode_tab.c
if [ $? -ne 0 ]
BISON_RETURN="$?"
if [ $BISON_RETURN -ne 0 ]
then
echo Compile error[$?], abort.
echo Compile error[$BISON_RETURN], abort.
exit 1
fi
flex -Cfa -B -8 -o ../../../src/sql/parser/sql_parser_mysql_mode_lex.c ../../../src/sql/parser/sql_parser_mysql_mode.l ../../../src/sql/parser/sql_parser_mysql_mode_tab.h