diff options
author | Karl Williamson <khw@cpan.org> | 2017-01-10 11:09:33 -0700 |
---|---|---|
committer | Karl Williamson <khw@cpan.org> | 2017-01-13 12:20:03 -0700 |
commit | 92e8e65053b85a7f695f0a1b5270a3567df87863 (patch) | |
tree | 6beb220e6c16602ecff16a807bd220913b61f0c8 /ext/Devel-Peek | |
parent | 75ea5c6c82d3602be563bf9c72e8b8e2c711225b (diff) | |
download | perl-92e8e65053b85a7f695f0a1b5270a3567df87863.tar.gz |
Various .t's: Escape literal '}' and ']' in patterns
It is clearer to show that these characters which are sometimes meta and
sometimes literal are meant to be taken literally here.
Diffstat (limited to 'ext/Devel-Peek')
-rw-r--r-- | ext/Devel-Peek/t/Peek.t | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/Devel-Peek/t/Peek.t b/ext/Devel-Peek/t/Peek.t index d62e3b21a1..4775c1c64f 100644 --- a/ext/Devel-Peek/t/Peek.t +++ b/ext/Devel-Peek/t/Peek.t @@ -77,7 +77,7 @@ sub do_test { # Could do this is in a s///mge but seems clearer like this: $pattern = join '', map { # If we identify the version condition, take *it* out whatever - s/\s*# (\$].*)$// + s/\s*# (\$\].*)$// ? (eval $1 ? $_ : '') : $_ # Didn't match, so this line is in } split /^/, $pattern; |