From: Robin Barker Date: Fri, 23 May 2003 17:42:37 +0000 (+0100) Subject: RE: state of deparse? X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=8e3542b6b408b9e409cdf6608e65d34ace8fb91e;p=p5sagit%2Fp5-mst-13.2.git RE: state of deparse? Message-ID: <533D273D4014D411AB1D00062938C4D90404653E@hotel.npl.co.uk> p4raw-id: //depot/perl@19601 --- diff --git a/ext/B/B/Deparse.pm b/ext/B/B/Deparse.pm index 06d795a..b700650 100644 --- a/ext/B/B/Deparse.pm +++ b/ext/B/B/Deparse.pm @@ -922,6 +922,10 @@ sub maybe_local { if ($op->private & (OPpLVAL_INTRO|$our_intro) and not $self->{'avoid_local'}{$$op}) { my $our_local = ($op->private & OPpLVAL_INTRO) ? "local" : "our"; + if( $our_local eq 'our' ) { + die "Unexpected our($text)\n" unless $text =~ /^\W(\w+::)*\w+\z/; + $text =~ s/(\w+::)+//; + } if (want_scalar($op)) { return "$our_local $text"; } else {