in reply to Hiding, but maintaining variables in user-defined code

i think it's unanimous -- we're confused by what it is you want. something i can't quite pin down suggests, though, that you might be helped by the fact that you can call

$obj->method->othermethod

if method above is something that returns another object. so if your first method returns an object with a particular relation (like, say, the parent or the first child or the appropriate filehandle) then you can say things like

my @sibs = $obj->parent->list_children; my $file = $obj->io->get_final_location;

etc. this means that knowing just $obj, you can get other relevant objects. but i'm not sure that's what you meant.

you also might want to check out caller(), which can tell you what sub called the sub you're in, and further back than that. but if you want to be able to look at variables from caller's POV (like, say, Caller(1)::$self) then you're out of luck, i think. you'll just have to pass them along as arguments.