glsl: Fixes warning: deprecated directive: ‘%pure-parser’, ‘%error-verbose’

../../src/compiler/glsl/glcpp/glcpp-parse.y:179.1-12: warning: deprecated directive: ‘%pure-parser’, use ‘%define api.pure’ [-Wdeprecated]
  179 | %pure-parser
      | ^~~~~~~~~~~~
      | %define api.pure
../../src/compiler/glsl/glcpp/glcpp-parse.y:180.1-14: warning: deprecated directive: ‘%error-verbose’, use ‘%define parse.error verbose’ [-Wdeprecated]
  180 | %error-verbose
      | ^~~~~~~~~~~~~~
      | %define parse.error verbose

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37289>
This commit is contained in:
Yonggang Luo 2023-12-15 22:00:07 +08:00 committed by Marge Bot
parent 7db518cfe4
commit bebd167d74
5 changed files with 8 additions and 8 deletions

View file

@ -176,8 +176,8 @@ add_builtin_define(glcpp_parser_t *parser, const char *name, int value);
%} %}
%pure-parser %define api.pure
%error-verbose %define parse.error verbose
%locations %locations
%initial-action { %initial-action {

View file

@ -82,8 +82,8 @@ static bool match_layout_qualifier(const char *s1, const char *s2,
%expect 0 %expect 0
%pure-parser %define api.pure
%error-verbose %define parse.error verbose
%locations %locations
%initial-action { %initial-action {

View file

@ -185,7 +185,7 @@ label(const char *str)
%type <num> xmov %type <num> xmov
%type <num> peek %type <num> peek
%error-verbose %define parse.error verbose
%start instrs %start instrs

View file

@ -804,7 +804,7 @@ static void print_token(FILE *file, int type, YYSTYPE value)
%type <unum> const_val cat6_src_shift %type <unum> const_val cat6_src_shift
%type <num> buf_type %type <num> buf_type
%error-verbose %define parse.error verbose
%start shader %start shader

View file

@ -128,11 +128,11 @@ static struct asm_instruction *asm_instruction_copy_ctor(
} while(0) } while(0)
%} %}
%pure-parser %define api.pure
%locations %locations
%lex-param { struct asm_parser_state *state } %lex-param { struct asm_parser_state *state }
%parse-param { struct asm_parser_state *state } %parse-param { struct asm_parser_state *state }
%error-verbose %define parse.error verbose
%union { %union {
struct asm_instruction *inst; struct asm_instruction *inst;