summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>2001-12-20 23:53:34 +0100
committerJarkko Hietaniemi <jhi@iki.fi>2001-12-20 20:53:42 +0000
commit8347ad866983eb3964e8afa626ea678bb02b5b4d (patch)
tree89300cdf50eb53a7700fd371e987a1d74bbf781f
parenteb2aae6f031274e8d45993b7ed0cf653eebff43f (diff)
downloadperl-8347ad866983eb3964e8afa626ea678bb02b5b4d.tar.gz
minor qr// fix
Message-ID: <20011220225334.A735@rafael> p4raw-id: //depot/perl@13821
-rw-r--r--ext/B/B/Deparse.pm9
1 files changed, 5 insertions, 4 deletions
diff --git a/ext/B/B/Deparse.pm b/ext/B/B/Deparse.pm
index fd8819167c..7bf95df56d 100644
--- a/ext/B/B/Deparse.pm
+++ b/ext/B/B/Deparse.pm
@@ -3158,10 +3158,11 @@ sub balanced_delim {
sub single_delim {
my($q, $default, $str) = @_;
return "$default$str$default" if $default and index($str, $default) == -1;
- my($succeed, $delim);
- ($succeed, $str) = balanced_delim($str);
- return "$q$str" if $succeed;
- for $delim ('/', '"', '#') {
+ if ($q ne 'qr') {
+ (my $succeed, $str) = balanced_delim($str);
+ return "$q$str" if $succeed;
+ }
+ for my $delim ('/', '"', '#') {
return "$q$delim" . $str . $delim if index($str, $delim) == -1;
}
if ($default) {