John M. Dlugosz has asked for the wisdom of the Perl Monks concerning the following question:
This affected the export-by-tag feature, and Exporter::VA uses itself, and both M2 and M3 used the ':normal' tag when importing Exporter::VA. So the second time it expanded to nothing.
That does not explain the observation that removing the 3rd call made the second work. Perhaps my early print statements were not clear enough when I first started exploring. Since this is what made me panic (cause should preceed effect!), it underscores the point that good note-taking and observations are essential. However, it's a truism that these things happen late at night when one is almost done implementing a new feature...so it generally doesn't get handled as formally (at first).
—John
Basically, the code looks like this:
The funny thing is that M3::import is never getting called, if and only if I have the M2 usage both before and after it. If I remove either of those, then M3 works fine.package C1; use M1 v1.0 qw/--verbose_import &foo bar baz quux bazola $ztesch --dum +p/; package C2; use M2 v1.0 qw/ foo baz $ztesch :tag1/; package C3; use M3 v1.0 qw/ --verbose_import foo --dump/; print "so what?\n"; package C4; use M2 v2.3.4.5 qw/foo baz --dump/;
I tried a simple test case, (files test2.perl, Dummy*.pm) but it did not reproduce the problem. My actual test, with stuff stripped out to make it what I show above, is it test1.perl. All this is posted at http://64.127.185.180/help1.zip (18305 bytes). Would someone take a look at it? Maybe it's just something I'm not seeing and need another pair of eyes.
Thanks,
—John
Update: When run, I expect the M3::import call to report its parameters, then die on foo. It should never get to the C4 usage of M2 (again) or the non-BEGIN stuff. Comment out one of the use M2's and see the difference.
|
|---|