# New Ticket Created by James Keenan # Please include the string: [perl #41897] # in the subject line of all future correspondence about this issue. # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=41897 >
I've found through experience that running Devel::Cover to perform coverage analysis on my code sometimes turns up problems that don't appear when running 'prove' or 'make test' without Devel::Cover. This was the case just now when, for the first time in a couple of months, I ran coverage analysis on Parrot::Pmc2c::Utils and its associated test suite, t/tools/pmc2cutils/*.t. See attached file. Note the warning, "Subroutine prederef redefined at Users/jimk/work/ fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10." This occurs in each of the 8 files in the test suite. It *only* appears when I'm running prove with Devel::Cover: PERL5OPT=-MDevel::Cover=-db,coverage/pmc2c prove t/tools/ pmc2cutils/*.t "$@" It does *not* appear when I run: prove -v t/tools/pmc2cutils/*.t These warnings do not impede any test from passing. But where there's smoke .... The facts that this warning (a) did not appear when I was running coverage analysis on this code back in November and December (b) occurs in each test file suggest that the offending line is: use Parrot::Pmc2c::PMETHODs; ... because that was put into Parrot::Pmc2c::Utils since I last worked on it. But I haven't yet looked into PMETHODs to see how it relates to STMRef. Googling for 'Subroutine prederef redefined' turns up 0 exact matches, but the closest match refers to Parrot. Ideas? Thank you very much. kid51
PERL5OPT=-MDevel::Cover=-db,coverage/pmc2c prove t/tools/pmc2cutils/*.t "$@" t/tools/pmc2cutils/00-qualify........Devel::Cover: Can't open -e for MD5 digest: No such file or directory t/tools/pmc2cutils/00-qualify........ok 1/9Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/00-qualify........ok t/tools/pmc2cutils/01-pmc2cutils.....ok 1/26Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/01-pmc2cutils.....ok t/tools/pmc2cutils/02-find_file......ok 1/7Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/02-find_file......ok t/tools/pmc2cutils/03-dump_vtable....ok 9/12Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/03-dump_vtable....ok t/tools/pmc2cutils/04-dump_pmc.......ok 113/117Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/04-dump_pmc.......ok t/tools/pmc2cutils/05-gen_c..........ok 63/68Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/05-gen_c..........ok t/tools/pmc2cutils/06-print_tree.....ok 33/55Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/06-print_tree.....ok t/tools/pmc2cutils/07-open_file......ok 19/23Subroutine prederef redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 10. Subroutine raw_deref redefined at /Users/jimk/work/fresh/t/tools/pmc2cutils/../../../lib/Parrot/Pmc2c/STMRef.pm line 34. t/tools/pmc2cutils/07-open_file......ok All tests successful. Files=8, Tests=317, 136 wallclock secs (111.11 cusr + 9.24 csys = 120.35 CPU)