http://qs1969.pair.com?node_id=1061499


in reply to Re^2: HTML::LinkExtor weirdness (scoping closures nested named subs)
in thread HTML::LinkExtor weirdness

The error message Variable "%s" will not stay shared is described in perldiag. The description is brief but explains the behavior you experienced. You can also read about closure in perlref, perlsub and elsewhere.