diff options
author | David Mitchell <davem@iabyn.com> | 2018-02-07 10:34:02 +0000 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2018-02-07 10:38:03 +0000 |
commit | 1848346ffa44e6cc26b51a9cc2ef878e44ae3dd8 (patch) | |
tree | bab54c15bbc894b0d101852146fdeb3741b0ebf6 /lib/B/Deparse.t | |
parent | ef80cd9998532b7e2be7823cd9af7ba1198822e5 (diff) | |
download | perl-1848346ffa44e6cc26b51a9cc2ef878e44ae3dd8.tar.gz |
fix tr/// Deparse tests under EBCDIC
Some tests I recently added had A-Z in the replacement charlist, which
under EBCDIC gets deparsed as A-IJ-RS-Z, so original and deparsed don't
match.
Ideally the deparsing could be smart enough to coalesce those ranges,
but for now I've just changed the range to A-I which deparses ok on both
ASCII and EBCDIC.
The point of the test is for when there are more replacement chars than
search chars, and in this case A-I works just as well as A-Z.
Spotted by Karl.
Diffstat (limited to 'lib/B/Deparse.t')
-rw-r--r-- | lib/B/Deparse.t | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/B/Deparse.t b/lib/B/Deparse.t index 3219e19b81..ffdfc6c67e 100644 --- a/lib/B/Deparse.t +++ b/lib/B/Deparse.t @@ -1448,15 +1448,15 @@ tr/X//r; tr/\000-\375/AB/c; tr/\000-\375/A-C/c; tr/\000-\375/A-D/c; -tr/\000-\375/A-Z/c; +tr/\000-\375/A-I/c; tr/\000-\375/AB/cd; tr/\000-\375/A-C/cd; tr/\000-\375/A-D/cd; -tr/\000-\375/A-Z/cd; +tr/\000-\375/A-I/cd; tr/\000-\375/AB/cds; tr/\000-\375/A-C/cds; tr/\000-\375/A-D/cds; -tr/\000-\375/A-Z/cds; +tr/\000-\375/A-I/cds; #### # [perl #119807] s//\(3)/ge should not warn when deparsed (\3 warns) s/foo/\(3);/eg; |