view release on metacpan or search on metacpan
lib/Astro/Catalog/Item.pm view on Meta::CPAN
my $self = shift;
if (@_) {
my $ra = shift;
# Issue a warning specifically for this call
my @info = caller();
warnings::warnif("deprecated","Use of ra() method for setting RA now deprecated. Please use the coords() method instead, at $info[1] line $info[2]");
# Get the coordinate object
my $c = $self->coords;
lib/Astro/Catalog/Item.pm view on Meta::CPAN
my $self = shift;
if (@_) {
my $dec = shift;
# Issue a warning specifically for this call
my @info = caller();
warnings::warnif("deprecated","Use of ra() method for setting RA now deprecated. Please use the coords() method instead, at $info[1] line $info[2]");
# Get the coordinate object
my $c = $self->coords;
if (defined $c) {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Astro/Coords.pm view on Meta::CPAN
return () unless exists $C->{$primary};
my $local = $C->{$primary};
return () unless defined $local;
my @answer = map { $local->{$_} } @keys;
# print "Caller: ". join(":", caller() ) ."\n";
# print "Getting cache values for ". join(":",@keys) ."\n";
# print "Getting cache values for ". join(":",@answer) ."\n";
return (wantarray() ? @answer : $answer[0] );
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Astro/FITS/HdrTrans/Base.pm view on Meta::CPAN
sub import {
my $class = shift;
# this is where we are going to install the methods
my $callpkg = caller();
# Prepend the from_ and to_ prefixes
for my $key (@_) {
# The key can be fully specified with from_ and to_ already
# In that case we do not want to loop over from_ and to_
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Astro/MoonPhase/Simple.pm view on Meta::CPAN
# Returns:
# a hash with results including 'asString' which contains a string description of the results.
# or undef on failure
sub calculate_moon_phase {
my $params = $_[0];
my $parent = ( caller(1) )[3] || "N/A";
my $whoami = ( caller(0) )[3];
if( ! defined($params) || ref($params) ne 'HASH' ){
print STDERR "$whoami (via $parent) : parameters in the form of a HASHref are required.";
return undef
}
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
chdir $cwd;
# import to main::
no strict 'refs';
*{'main::WriteMakefile'} = \&Write if caller(0) eq 'main';
}
sub _running_under {
my $thing = shift;
print <<"END_MESSAGE";
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
chdir $cwd;
# import to main::
no strict 'refs';
*{'main::WriteMakefile'} = \&Write if caller(0) eq 'main';
}
# Check to see if we are currently running under CPAN.pm and/or CPANPLUS;
# if we are, then we simply let it taking care of our dependencies
sub _check_lock {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Astro/SIMBAD/Client.pm view on Meta::CPAN
$fragment =~ s< \A / ><>smx; # Defensive programming
return sprintf '%s://%s/%s', $self->get( 'scheme' ),
$self->get( 'server' ), $fragment;
}
# _callers_caller();
#
# Returns the name of the subroutine that called the caller.
# Results undefined if not called from a subroutine nested at
# least two deep.
lib/Astro/SIMBAD/Client.pm view on Meta::CPAN
my $ua = _get_user_agent ();
$self->_delay ();
my $resp;
if (eval {$url->isa('HTTP::Request')}) {
$debug
and print 'Debug ', _callers_caller(), 'executing ',
$url->as_string, "\n";
$resp = $ua->request ($url);
} elsif ($self->get ('post') && %$args) {
if ($debug) {
print 'Debug ', _callers_caller(), " posting to $url\n";
foreach my $key (sort keys %$args) {
print " $key => $args->{$key}\n";
}
}
$resp = $ua->post ($url, $args);
lib/Astro/SIMBAD/Client.pm view on Meta::CPAN
$url .= $join . _escape_uri( $key ) . '=' . _escape_uri (
$args->{$key} );
$join = '&';
}
$debug
and print 'Debug ', _callers_caller(), " getting from $url\n";
$resp = $ua->get( $url );
}
$debug
and print 'Debug - request: ', $resp->request()->as_string(), "\n";
view all matches for this distribution
view release on metacpan or search on metacpan
Table/Base.pm view on Meta::CPAN
sub METHOD::ABSTRACT
{
my ($self) = @_;
my $object_class = ref($self);
my ($file, $line, $method) = (caller(1))[1..3];
my $loc = "at $file, line $line\n";
die "call to abstract method ${method} $loc";
}
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@found;
}
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
1;
view all matches for this distribution
view release on metacpan or search on metacpan
script/satpass view on Meta::CPAN
# call to back off; the default is 1, meaning to get the suffix
# of the caller.
sub _get_suffix {
my ( $prefix, $backoff ) = @_;
my $rtn = ( caller( $backoff || 1 ) )[3];
$rtn =~ s/ .* :: //smx;
$rtn =~ s/ \A _+ //smx;
$rtn = substr $rtn, length $prefix;
$rtn =~ s/ __ .* //smx;
$rtn;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Async/Chain.pm view on Meta::CPAN
=cut
# Internal method called by use function
sub import {
$caller = (caller())[0];
*{$caller . "::chain"} = \&chain;
}
# Internal method used for reduction to code.
sub _to_code {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Async/Event/Interval.pm view on Meta::CPAN
# On events with interval of zero, ForkManager runs finish(), which
# calls our destroy method. We only want to blow away the %events
# hash if we truly go out of scope
return if (caller())[0] eq 'Parallel::ForkManager::Child';
delete $events{$_[0]->id};
}
sub _end {
if (! keys %events) {
view all matches for this distribution
view release on metacpan or search on metacpan
t/30-tons_of_sync.t view on Meta::CPAN
use Async::Queue;
sub stack_frame_num {
my $num = 0;
while(caller($num)) {
$num++;
}
return $num;
}
view all matches for this distribution
view release on metacpan or search on metacpan
src/ppport.h view on Meta::CPAN
ccstack = top_si->si_cxstack;
cxix = DPPP_dopoptosub_at(ccstack, top_si->si_cxix);
}
if (cxix < 0)
return NULL;
/* caller() should not report the automatic calls to &DB::sub */
if (PL_DBsub && GvCV(PL_DBsub) && cxix >= 0 &&
ccstack[cxix].blk_sub.cv == GvCV(PL_DBsub))
count++;
if (!count--)
break;
src/ppport.h view on Meta::CPAN
if (CxTYPE(cx) == CXt_SUB || CxTYPE(cx) == CXt_FORMAT) {
const I32 dbcxix = DPPP_dopoptosub_at(ccstack, cxix - 1);
/* We expect that ccstack[dbcxix] is CXt_SUB, anyway, the
field below is defined for any cx. */
/* caller() should not report the automatic calls to &DB::sub */
if (PL_DBsub && GvCV(PL_DBsub) && dbcxix >= 0 && ccstack[dbcxix].blk_sub.cv == GvCV(PL_DBsub))
cx = &ccstack[dbcxix];
}
return cx;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/At/Error.pm view on Meta::CPAN
push @stack, $info;
}
}
method _caller_info($i) {
my ( $package, $filename, $line, $subroutine ) = caller($i);
return unless $package;
return { package => $package, file => $filename, line => $line, sub_name => $subroutine };
}
method throw() {
my ( undef, $file, $line ) = caller();
my $msg = join "\n\t", sprintf( qq[%s at %s line %d\n], $message, $file, $line ),
map { sprintf q[%s called at %s line %d], $_->{sub_name}, $_->{file}, $_->{line} } @stack;
$fatal ? die "$msg\n" : warn "$msg\n";
}
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
chdir $cwd;
# import to main::
no strict 'refs';
*{'main::WriteMakefile'} = \&Write if caller(0) eq 'main';
return (@Existing, @Missing);
}
sub _running_under {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
# Done in evals to avoid confusing Perl::MinimumVersion
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Common Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
bench/attr_bench.pl view on Meta::CPAN
use Cache::MemoryCache;
my %caches;
sub getCache {
my (undef, undef, undef, $method) = caller(2);
return $caches{$method} ||= do {
warn "Getting cache $method";
Cache::MemoryCache->new({namespace=>$method});
};
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Attribute/Default.pm view on Meta::CPAN
## once 'exsub' is exported for compile-time speed.
##
sub import {
my $class = shift;
my ($subname) = @_;
my $callpkg = (caller())[0];
if (defined($subname) && $subname eq 'exsub') {
no strict 'refs';
*{ "${callpkg}::exsub" } = \&exsub;
}
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
#####################################################################
# Utility Functions
sub _caller {
my $depth = 0;
my $call = caller($depth);
while ( $call eq __PACKAGE__ ) {
$depth++;
$call = caller($depth);
}
return $call;
}
sub _read {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Attribute/GlobalEnable.pm view on Meta::CPAN
my $class = shift();
croak "Must specify some arguments." if not @_;
my $args = {@_};
## set the package to the caller
$PACKAGE = caller();
croak "Must sub-package ".$PACKAGE if not $PACKAGE or $PACKAGE eq __PACKAGE__;
## make sure our sub-packaged module is using the exporter
_export_the_exporter_to( $PACKAGE ) or die "Bad exporting exporter";
lib/Attribute/GlobalEnable.pm view on Meta::CPAN
my $debug_level = _is_flag_on($attribute, $flag);
if( not defined $debug_level ) {
unshift( @_, $flag ) if not defined $debug_level;
}
my $full_package = (caller(2))[3];
my $caller_sub_name = '';
GET_PROPER_PACKAGE_NAME: {
my @packages = split /::/, $full_package;
pop @packages;
view all matches for this distribution
view release on metacpan or search on metacpan
demo/Demo.pm view on Meta::CPAN
"with data ($data)\nin phase $phase\n";
};
sub This : ATTR(SCALAR) {
print STDERR "This at ",
join(":", map { defined() ? $_ : "" } caller(1)),
"\n";
}
sub Demo : ATTR(HASH) {
my ($package, $symbol, $referent, $attr, $data) = @_;
view all matches for this distribution
view release on metacpan or search on metacpan
demo/Demo.pm view on Meta::CPAN
"with data (@$data)\nin phase $phase\n";
};
sub This : ATTR(SCALAR) {
print STDERR "This at ",
join(":", map { defined() ? $_ : "" } caller(1)),
"\n";
}
sub Multi : ATTR(RAWDATA) {
my ($package, $symbol, $referent, $attr, $data) = @_;
view all matches for this distribution
view release on metacpan or search on metacpan
demo/Demo.pm view on Meta::CPAN
"with data ($data)\nin phase $phase\n";
};
sub This : ATTR(SCALAR) {
print STDERR "This at ",
join(":", map { defined() ? $_ : "" } caller(1)),
"\n";
}
sub Demo : ATTR(HASH) {
my ($package, $symbol, $referent, $attr, $data) = @_;
view all matches for this distribution