This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
t/perf/optree.t: better diagnostics
authorDavid Mitchell <davem@iabyn.com>
Thu, 13 Jul 2017 13:09:55 +0000 (14:09 +0100)
committerDavid Mitchell <davem@iabyn.com>
Thu, 27 Jul 2017 10:30:23 +0000 (11:30 +0100)
commit7caeb7be934ab798a490d6205914121a6a935f01
tree26123b7a79472db04895ad0ccb778417720d04cc
parent7be75ccf16313d987eb5a6e9ff6aec9fea4ef3d4
t/perf/optree.t: better diagnostics

when it fails to the find the op its looking for, dump the optree.

Also, include the grep tests in parentheses, otherwise the condition
can be interpreted as the whole expression if the condition includes
parentheses;

e.g. condition: ($a==$_)

    becomes grep ($a==$_), 1, 2

so do this instead

    becomes grep (($a==$_), 1, 2)
t/perf/optree.t