Branch: refs/heads/davem/deparse
  Home:   https://github.com/Perl/perl5
  Commit: 50d9a0bc1359cb9f2162ab408e48eaf57b8cc523
      
https://github.com/Perl/perl5/commit/50d9a0bc1359cb9f2162ab408e48eaf57b8cc523
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M Porting/deparse-skips.txt

  Log Message:
  -----------
  deparse-skips.txt: update bignum/t/*.t entries

In general, cpan/bignum test scripts don't survive a Deparse round-trip
due to the code references in the hints hash getting stringified.

Update Porting/deparse-skips.txt with all the new/renamed test
scripts under cpan/bignum/t which have been added in the last year
(since the last time I checked deparse-skips.txt).

For some reason cpan/bignum/t/scope-nested-const.t has started working.


  Commit: 96e13335507574cbb084d0d8e868a26c45028d60
      
https://github.com/Perl/perl5/commit/96e13335507574cbb084d0d8e868a26c45028d60
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M Porting/deparse-skips.txt

  Log Message:
  -----------
  Porting/deparse-skips.txt: remove deleted files

A few test files listed for skipping are no longer present, so remove
them from deparse-skips.txt


  Commit: 16f77ed74eb24a7b859630174edabd79f559acb4
      
https://github.com/Perl/perl5/commit/16f77ed74eb24a7b859630174edabd79f559acb4
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M lib/B/Deparse.pm
    M lib/B/Deparse.t

  Log Message:
  -----------
  Deparse.pm: handle padsv_store in list cxt

The recently added op, OP_PADSV_STORE, which combines PADSV and
SASSIGN ops into a single op on something like

    my $lex = 1;

wasn't being deparsed correctly in list context, e.g.

    @foo = (my $x = 1);

This is because the pp_list() sub in Deparse.pm directly handles any pad
ops itself when it sees a list - such as in my ($x, $y, $z) - rather
than leaving pp_padsv(), pp_padsv_store() etc to deal with the
individual elements.  So update pp_list() to handle a padsv_store op.

Note that the second added test, for 'state', didn't actually fail, but
I added a test anyway, in case a future change makes the optree such
that it goes down this code path instead.


  Commit: cc6155ae7b86d90bb963686d6ffddb4f1ba610d3
      
https://github.com/Perl/perl5/commit/cc6155ae7b86d90bb963686d6ffddb4f1ba610d3
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M Porting/deparse-skips.txt

  Log Message:
  -----------
  deparse-skips.txt: exclude class/*.t

None of the class test files currently survive a Deparse round-trip,
due to (at first glance) Deparse.pm not recognising the OP_METHSTART op.

Mark all these files as expected-to-fail for now.


  Commit: fad9ea6128290574aef7af308fdeb5b374f458d3
      
https://github.com/Perl/perl5/commit/fad9ea6128290574aef7af308fdeb5b374f458d3
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M lib/B/Deparse.pm

  Log Message:
  -----------
  Deparse.pm: handle signatures under 'use v5.36'

Deparse.pm was checking for the equivalent of

    use feature 'signatures';

being in scope when deciding whether to deparse a sub using signature
syntax. However, since 5.36.0, signatures can also be be enabled via

    use v5.36;

but Deparse wasn't checking for this (the latter is stored in hints
rather than in features).

I haven't added a test as 'use v.5.36' itself currently doesn't deparse
cleanly; however, this commit means that

    #use feature 'signatures';
    use v5.36;

    sub f($x,$y) {
        return $x + $y;
    }

used to deparse as:

    sub f {
        do {
            die sprintf("Too many arguments for subroutine at %s line %d.\n", 
(caller)[1, 2]) unless @_ <= 2;
        ...
    }

but now correctly deparses as:

    sub f ($x, $y) {
        ...
    }

Uncommenting the 'use feature' line instead worked both before and now.

It was showing up as this failing:

    cd t; ./TEST -deparse ../lib/builtin.t


  Commit: 66b8376935373b4e0929fd87c8f6132989bcebcc
      
https://github.com/Perl/perl5/commit/66b8376935373b4e0929fd87c8f6132989bcebcc
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M Porting/deparse-skips.txt

  Log Message:
  -----------
  deparse-skips.txt: skip undef.t, opcount.t for now

Both these files have had tests added using this unusual construct:

    keys %{($h=undef)||{}}

which currently gets deparsed as

    keys %{ {} unless $h=undef }

which then confuses the parser.


  Commit: 4a9549e948cccb05e564ea70258a4a733153059a
      
https://github.com/Perl/perl5/commit/4a9549e948cccb05e564ea70258a4a733153059a
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M Porting/deparse-skips.txt

  Log Message:
  -----------
  deparse-skips.txt: remove now-passing tests

t/op/hexfp.t and ext/XS-APItest/t/svpeek.t have both started surviving
a Deparse round trip. I haven't looked at why, but this commit
removes them from the list of expected failures.


  Commit: 46a00d5aacf9013e940287a6dd5fbd2026e3e6dd
      
https://github.com/Perl/perl5/commit/46a00d5aacf9013e940287a6dd5fbd2026e3e6dd
  Author: David Mitchell <da...@iabyn.com>
  Date:   2023-05-19 (Fri, 19 May 2023)

  Changed paths:
    M Porting/deparse-skips.txt

  Log Message:
  -----------
  Porting/deparse-skips.txt: skip t/e/pat_re_eval.t

The new /(*{...})/ form introduced by v5.37.7-155-gc224bbd5d1 isn't
yet correctly deparsed, so for now ignore round-trip Deparse errors
from the test file which contains it.


Compare: https://github.com/Perl/perl5/compare/50d9a0bc1359%5E...46a00d5aacf9

Reply via email to