mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
diagnostics: improve accuracy for deprecated %define variables
* src/parse-gram.y: Use the location of the whole definition to record the location of a %define variable, instead of just the name of the variable. Adjust tests.
This commit is contained in:
@@ -32,7 +32,7 @@ exp: %empty;
|
||||
]])
|
||||
|
||||
AT_BISON_CHECK([[input.y]], [[1]], [[]],
|
||||
[[input.y:2.9-22: error: '%union' and '%define api.value.type' cannot be used together
|
||||
[[input.y:2.1-38: error: '%union' and '%define api.value.type' cannot be used together
|
||||
]])
|
||||
|
||||
AT_CLEANUP
|
||||
@@ -51,7 +51,7 @@ exp: %empty;
|
||||
]])
|
||||
|
||||
AT_BISON_CHECK([[input.y]], [[1]], [[]],
|
||||
[[input.y:2.9-22: error: '%yacc' and '%define api.value.type "union"' cannot be used together
|
||||
[[input.y:2.1-28: error: '%yacc' and '%define api.value.type "union"' cannot be used together
|
||||
]])
|
||||
|
||||
AT_CLEANUP
|
||||
|
||||
Reference in New Issue
Block a user