mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-10 12:53:03 +00:00
tests: use perl for printing special sequences to files.
And skip tests if perl is not available. This is better than
playing tricks with shell portability. Suggested by Akim
Demaille.
* tests/input.at (Bad escapes in literals): Use it here for special
characters.
(cherry picked from commit b70c7fb4e1)
Conflicts:
tests/input.at
This commit is contained in:
10
ChangeLog
10
ChangeLog
@@ -1,3 +1,13 @@
|
||||
2009-08-27 Joel E. Denny <jdenny@clemson.edu>
|
||||
|
||||
tests: use perl for printing special sequences to files.
|
||||
And skip tests if perl is not available. This is better than
|
||||
playing tricks with shell portability. Suggested by Akim
|
||||
Demaille.
|
||||
* tests/input.at (Bad character literals): Use it here for
|
||||
omitting final newlines.
|
||||
(Bad escapes in literals): Use it here for special characters.
|
||||
|
||||
2009-08-21 Joel E. Denny <jdenny@clemson.edu>
|
||||
|
||||
Use locale when quoting.
|
||||
|
||||
@@ -953,7 +953,13 @@ start: '\777' '\0' '\xfff' '\x0'
|
||||
'\uffff' '\u0000' '\Uffffffff' '\U00000000'
|
||||
'\ ' '\A';
|
||||
]])
|
||||
echo 'start: "\T\F\0\1" ;' | tr 'TF01' '\011\014\0\1' >> input.y
|
||||
|
||||
# It is not easy to create special characters, we cannot even trust tr.
|
||||
# Beside we cannot even expect "echo '\0'" to output two characters
|
||||
# (well three with \n): at least Bash 3.2 converts the two-character
|
||||
# sequence "\0" into a single NUL character.
|
||||
AT_CHECK([[perl -e 'print "start: \"\\\t\\\f\\\0\\\1\" ;";' >> input.y \
|
||||
|| exit 77]])
|
||||
|
||||
AT_BISON_CHECK([input.y], [1], [],
|
||||
[[input.y:2.9-12: invalid number after \-escape: 777
|
||||
|
||||
Reference in New Issue
Block a user