Help for this page
{ package a; ... # or the temp variable can be avoided: print ${ "$otherpkg\::foo" }, "\n"; }
use strict; { ... my $otherpkg = "a"; print $otherpkg->foo, "\n"; }