projects
/
platform
/
upstream
/
perl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
da21930
)
&_q needs to *globally* escape ' and \ in its substitution.
author
Nicholas Clark
<nick@ccl4.org>
Thu, 27 Jan 2005 11:12:34 +0000
(11:12 +0000)
committer
Nicholas Clark
<nick@ccl4.org>
Thu, 27 Jan 2005 11:12:34 +0000
(11:12 +0000)
p4raw-id: //depot/perl@23883
t/test.pl
patch
|
blob
|
history
diff --git
a/t/test.pl
b/t/test.pl
index
36a12c3
..
7550b49
100644
(file)
--- a/
t/test.pl
+++ b/
t/test.pl
@@
-101,8
+101,8
@@
sub _q {
my $x = shift;
return 'undef' unless defined $x;
my $q = $x;
- $q =~ s/\\/\\\\/;
- $q =~ s/'/\\'/;
+ $q =~ s/\\/\\\\/
g
;
+ $q =~ s/'/\\'/
g
;
return "'$q'";
}