Programming :  Student Freelance Forum For Work Experience Builders' (CertificationPoint) The fastest message board... ever.
 
PERL-Accessing Variables from the Caller's Package
Posted by: adcertpoint (Moderator)
Date: April 29, 2020 04:37PM

Sometimes you want to access variables from the caller's package. One way is to do something like this:
{
no strict 'vars' ;
my $caller = caller;
print qq[$caller --- ${"${caller}::var"}];
}

Options: ReplyQuote


Sorry, only registered users may post in this forum.
This forum powered by Phorum.