mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-21 02:03:03 +00:00
deterministic test suite.
Some consistency checks on symbols are performed after all the symbols were read, by an iteration over the symbol table. This traversal is nondeterministic, which can be a problem for test cases. Avoid this. Addresses another form of nondeterminism reported by Joel E. Denny. http://lists.gnu.org/archive/html/bison-patches/2009-05/msg00023.html * tests/input.at (Numbered tokens): Split the hexadecimal/decimal test in two. Use different file names for the three tests to make the maintenance easier.
This commit is contained in:
16
ChangeLog
16
ChangeLog
@@ -1,3 +1,19 @@
|
|||||||
|
2009-06-10 Akim Demaille <demaille@gostai.com>
|
||||||
|
|
||||||
|
deterministic test suite.
|
||||||
|
Some consistency checks on symbols are performed after all the
|
||||||
|
symbols were read, by an iteration over the symbol table. This
|
||||||
|
traversal is nondeterministic, which can be a problem for test
|
||||||
|
cases.
|
||||||
|
Avoid this.
|
||||||
|
Addresses another form of nondeterminism reported by Joel E. Denny.
|
||||||
|
http://lists.gnu.org/archive/html/bison-patches/2009-05/msg00023.html
|
||||||
|
|
||||||
|
* tests/input.at (Numbered tokens): Split the hexadecimal/decimal
|
||||||
|
test in two.
|
||||||
|
Use different file names for the three tests to make the
|
||||||
|
maintenance easier.
|
||||||
|
|
||||||
2009-06-10 Akim Demaille <demaille@gostai.com>
|
2009-06-10 Akim Demaille <demaille@gostai.com>
|
||||||
|
|
||||||
gnulib: update.
|
gnulib: update.
|
||||||
|
|||||||
2
gnulib
2
gnulib
Submodule gnulib updated: 31d3154399...5a1286a9f8
@@ -675,24 +675,33 @@ AT_CLEANUP
|
|||||||
|
|
||||||
AT_SETUP([Numbered tokens])
|
AT_SETUP([Numbered tokens])
|
||||||
|
|
||||||
AT_DATA_GRAMMAR([input.y],
|
AT_DATA_GRAMMAR([1.y],
|
||||||
[[%token HEXADECIMAL_1 0xabcdef
|
[[%token DECIMAL 11259375
|
||||||
DECIMAL_1 11259375
|
HEXADECIMAL 0xabcdef
|
||||||
%token HEXADECIMAL_2 0XFEDCBA
|
|
||||||
DECIMAL_2 16702650
|
|
||||||
%%
|
|
||||||
start: HEXADECIMAL_1 HEXADECIMAL_2
|
|
||||||
%%
|
%%
|
||||||
|
start: DECIMAL;
|
||||||
]])
|
]])
|
||||||
|
|
||||||
AT_BISON_CHECK([input.y], [1], [],
|
AT_BISON_CHECK([1.y], [1], [],
|
||||||
[[input.y:10.12-20: user token number 11259375 redeclaration for DECIMAL_1
|
[[1.y:10.10-20: user token number 11259375 redeclaration for HEXADECIMAL
|
||||||
input.y:9.8-20: previous declaration for HEXADECIMAL_1
|
1.y:9.8-14: previous declaration for DECIMAL
|
||||||
input.y:12.12-20: user token number 16702650 redeclaration for DECIMAL_2
|
|
||||||
input.y:11.8-20: previous declaration for HEXADECIMAL_2
|
|
||||||
]])
|
]])
|
||||||
|
|
||||||
AT_DATA_GRAMMAR([input.y],
|
|
||||||
|
AT_DATA_GRAMMAR([2.y],
|
||||||
|
[[%token HEXADECIMAL 0xabcdef
|
||||||
|
DECIMAL 11259375
|
||||||
|
%%
|
||||||
|
start: HEXADECIMAL;
|
||||||
|
]])
|
||||||
|
|
||||||
|
AT_BISON_CHECK([2.y], [1], [],
|
||||||
|
[[2.y:10.10-16: user token number 11259375 redeclaration for DECIMAL
|
||||||
|
2.y:9.8-18: previous declaration for HEXADECIMAL
|
||||||
|
]])
|
||||||
|
|
||||||
|
|
||||||
|
AT_DATA_GRAMMAR([3.y],
|
||||||
[[%token TOO_LARGE_DEC 999999999999999999999
|
[[%token TOO_LARGE_DEC 999999999999999999999
|
||||||
TOO_LARGE_HEX 0xFFFFFFFFFFFFFFFFFFF
|
TOO_LARGE_HEX 0xFFFFFFFFFFFFFFFFFFF
|
||||||
%%
|
%%
|
||||||
@@ -700,9 +709,9 @@ start: TOO_LARGE_DEC TOO_LARGE_HEX
|
|||||||
%%
|
%%
|
||||||
]])
|
]])
|
||||||
|
|
||||||
AT_BISON_CHECK([input.y], [1], [],
|
AT_BISON_CHECK([3.y], [1], [],
|
||||||
[[input.y:9.22-42: integer out of range: `999999999999999999999'
|
[[3.y:9.22-42: integer out of range: `999999999999999999999'
|
||||||
input.y:10.24-44: integer out of range: `0xFFFFFFFFFFFFFFFFFFF'
|
3.y:10.24-44: integer out of range: `0xFFFFFFFFFFFFFFFFFFF'
|
||||||
]])
|
]])
|
||||||
|
|
||||||
AT_CLEANUP
|
AT_CLEANUP
|
||||||
|
|||||||
Reference in New Issue
Block a user