This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Deparse my var attributes correctly
Formerly this:
my $x :foo;
deparsed as
'attributes'->import('main', \$x, 'foo'), my $x;
it now deparses as:
my $x :foo;
It handles all the common forms, such as
my Foo::Bar ($s, @a, %h) :foo(foo1) bar(bar1);
but doesn't yet handle an attribute declaration that's not a statement,
e.g.
f(1, $x :foo);
Under TEST -deparse, this fixes the following unexpectedly failing
scripts:
../dist/IO/t/io_file_export.t
../dist/IO/t/io_multihomed.t
../dist/IO/t/io_udp.t
../dist/Thread-Queue/t/02_refs.t
../dist/Thread-Semaphore/t/01_basic.t
../dist/Thread-Semaphore/t/04_nonblocking.t
../dist/Thread-Semaphore/t/05_force.t
../dist/Thread-Semaphore/t/06_timed.t
../dist/threads-shared/t/av_refs.t
../dist/threads-shared/t/blessed.t
../dist/threads-shared/t/clone.t
../dist/threads-shared/t/cond.t
../dist/threads-shared/t/dualvar.t
../dist/threads-shared/t/hv_refs.t
../dist/threads-shared/t/object.t
../dist/threads-shared/t/object2.t
../dist/threads-shared/t/shared_attr.t
../dist/threads-shared/t/sv_refs.t
../dist/threads-shared/t/utf8.t
../dist/threads-shared/t/wait.t
../dist/threads-shared/t/waithires.t
../dist/threads/t/err.t
../dist/threads/t/free.t
../dist/threads/t/join.t
../dist/threads/t/kill.t
../dist/threads/t/kill2.t
../dist/threads/t/libc.t
../dist/threads/t/problems.t
../dist/threads/t/state.t
op/threads-dirh.t
and fixes the following expected-to-fail scripts:
../dist/Thread-Queue/t/08_nothreads.t
../dist/threads/t/exit.t
../dist/threads/t/thread.t
op/attrs.t
op/getpid.t