summaryrefslogtreecommitdiff
path: root/lib/AutoSplit.pm
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>2003-08-09 12:43:50 +0000
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>2003-08-09 12:43:50 +0000
commit957f93eee96ef9053b2451ad433491dc67fedaa4 (patch)
tree65534e061ebe824807a62833d13f5aff1d8278c4 /lib/AutoSplit.pm
parentb30f304ae36b3931349d7d5816f5a5646afe5397 (diff)
downloadperl-957f93eee96ef9053b2451ad433491dc67fedaa4.tar.gz
Change #20578 to SelfLoader is probably also useful to AutoSplit.
p4raw-id: //depot/perl@20583
Diffstat (limited to 'lib/AutoSplit.pm')
-rw-r--r--lib/AutoSplit.pm8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/AutoSplit.pm b/lib/AutoSplit.pm
index 7fd9487bc9..9355bfd9d3 100644
--- a/lib/AutoSplit.pm
+++ b/lib/AutoSplit.pm
@@ -148,10 +148,12 @@ if (defined (&Dos::UseLFN)) {
my $Is_VMS = ($^O eq 'VMS');
# allow checking for valid ': attrlist' attachments
-my $nested;
+# (we use 'our' rather than 'my' here, due to the rather complex and buggy
+# behaviour of lexicals with qr// and (??{$lex}) )
+our $nested;
$nested = qr{ \( (?: (?> [^()]+ ) | (??{ $nested }) )* \) }x;
-my $one_attr = qr{ (?> (?! \d) \w+ (?:$nested)? ) (?:\s*\:\s*|\s+(?!\:)) }x;
-my $attr_list = qr{ \s* : \s* (?: $one_attr )* }x;
+our $one_attr = qr{ (?> (?! \d) \w+ (?:$nested)? ) (?:\s*\:\s*|\s+(?!\:)) }x;
+our $attr_list = qr{ \s* : \s* (?: $one_attr )* }x;