PMf_MULTILINE PMf_SINGLELINE PMf_FOLD PMf_EXTENDED),
($] < 5.009 ? 'PMf_SKIPWHITE' : 'RXf_SKIPWHITE'),
($] < 5.011 ? 'CVf_LOCKED' : ());
-$VERSION = 0.89;
+$VERSION = 0.90;
use strict;
use vars qw/$AUTOLOAD/;
use warnings ();
next unless $AF eq $0 || exists $self->{'files'}{$AF};
}
push @{$self->{'protos_todo'}}, [$pack . $key, $val->PV];
- } elsif ($class eq "IV") {
+ } elsif ($class eq "IV" && !($val->FLAGS & SVf_ROK)) {
# Just a name. As above.
+ # But skip proxy constant subroutines, as some form of perl-space
+ # visible code must have created them, be it a use statement, or
+ # some direct symbol-table manipulation code that we will Deparse
my $A = $stash{"AUTOLOAD"};
if (defined ($A) && class($A) eq "GV" && defined($A->CV)
&& class($A->CV) eq "CV") {
require feature;
feature->import(':5.10');
}
-use Test::More tests => 77;
+use Test::More tests => 78;
use Config ();
use B::Deparse;
EOF
is($a, $b);
+$a = `$^X $path "-MO=Deparse" -e "use constant PI => 4" 2>&1`;
+$a =~ s/-e syntax OK\n//g;
+is($a, "use constant ('PI', 4);\n",
+ "Proxy Constant Subroutines must not show up as (incorrect) prototypes");
+
#Re: perlbug #35857, patch #24505
#handle warnings::register-ed packages properly.
package B::Deparse::Wrapper;