view release on metacpan or search on metacpan
lib/Event/ExecFlow/Job/Group.pm view on Meta::CPAN
package Event::ExecFlow::Job::Group;
use base qw( Event::ExecFlow::Job );
use strict;
use Scalar::Util qw(weaken);
sub get_type { "group" }
sub get_jobs { shift->{jobs} }
sub get_fail_with_members { shift->{fail_with_members} }
lib/Event/ExecFlow/Job/Group.pm view on Meta::CPAN
$self->SUPER::init();
foreach my $job ( @{$self->get_jobs} ) {
$job->set_group($self);
weaken($job->{group});
$self->add_child_post_callback($job);
}
$self->set_progress_max($self->get_job_cnt);
lib/Event/ExecFlow/Job/Group.pm view on Meta::CPAN
my $self = shift;
foreach my $job ( @{$self->get_jobs} ) {
if ( $job->get_type eq 'group' ) {
$job->set_group($self);
weaken($job->{group});
$job->set_group_in_all_childs;
}
else {
$job->set_group($self);
weaken($job->{group});
}
}
1;
}
lib/Event/ExecFlow/Job/Group.pm view on Meta::CPAN
push @{$self->get_jobs}, $job;
$job->set_frontend($self->get_frontend);
$job->set_group($self);
weaken($job->{group});
my $job_cnt = $job->get_job_cnt;
$self->increase_progress_max($job_cnt) if $job_cnt != 0;
if ( $self->get_state eq 'finished' ||
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Event/Wrappable.pm view on Meta::CPAN
{
$Event::Wrappable::VERSION = '0.1.1';
}
use strict;
use warnings;
use Scalar::Util qw( refaddr weaken );
use Sub::Exporter -setup => {
exports => [qw( event event_method )],
groups => { default => [qw( event event_method )] },
};
use Sub::Clone qw( clone_sub );
lib/Event/Wrappable.pm view on Meta::CPAN
sub _new {
my $class = shift;
my( $event, $raw_event ) = @_;
bless $event, $class;
my $storage = $INSTANCES{refaddr $event} = {};
weaken( $storage->{'wrapped'} = $event );
weaken( $storage->{'base'} = $raw_event );
$storage->{'wrappers'} = [ @EVENT_WRAPPERS ];
$storage->{'id'} = ++ $LAST_ID;
return $event;
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Evented/API/Engine.pm view on Meta::CPAN
use warnings;
use strict;
use 5.010;
use JSON::XS;
use Scalar::Util qw(weaken blessed);
use Module::Loaded qw(mark_as_loaded mark_as_unloaded is_loaded);
use Evented::Object;
use parent 'Evented::Object';
our $VERSION = '4.13';
lib/Evented/API/Engine.pm view on Meta::CPAN
];
# make the API Engine listen to the events of the module.
# hold a weak reference to the API engine.
$mod->add_listener($api, 'module');
weaken($mod->{api} = $api);
# here we fire an event which will export symbols for convenient use
# within the module packages. see Module.pm for defaults.
$mod->fire(set_variables => $_) for @pkgs;
lib/Evented/API/Engine.pm view on Meta::CPAN
my ($api, $mod, $mod_name, $submod_name) = @_;
# postpone load until the companion is loaded.
# hold a weak reference to the module waiting.
my $waits = $api->{companion_waits}{$mod_name} ||= [];
my $ref = [ $mod, $submod_name ]; weaken($ref->[0]);
push @$waits, $ref;
# if it is already loaded, go ahead and load the submodule.
if (my $loaded = $api->get_module($mod_name)) {
return $api->_load_companion_submodules($loaded);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Evented/Object.pm view on Meta::CPAN
BEGIN {
$events = 'eventedObject.events';
$props = 'eventedObject.props';
}
use Scalar::Util qw(weaken blessed);
use Evented::Object::EventFire;
use Evented::Object::Collection;
our $VERSION = '5.68';
lib/Evented/Object.pm view on Meta::CPAN
my $listeners = $eo->{$props}{listeners} ||= [];
# store this listener.
push @$listeners, [$prefix, $obj];
# weaken the reference to the listener.
weaken($listeners->[$#$listeners][1]);
return 1;
}
# ->delete_listener()
lib/Evented/Object.pm view on Meta::CPAN
my $m = $monitors{$pkg} ||= [];
return if grep { $_ == $obj } @$m = grep { defined } @$m;
# hold a weak reference to the monitor.
push @$m, $obj;
weaken($monitors{$pkg}[$#$m]);
return 1;
}
# delete_class_monitor()
lib/Evented/Object.pm view on Meta::CPAN
foreach my $priority (keys %$store) {
# create a group reference.
my $group_id = "$eo/$event_name";
my $group = [ $eo, $event_name, \@args, $group_id ];
weaken($group->[0]);
# add each callback set. inject callback name.
foreach my $cb_ref (@{ $store->{$priority} }) {
my %cb = %$cb_ref; # make a copy
$cb{id} = "$group_id/$cb{name}";
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Evo/Ee.pm view on Meta::CPAN
my $ref = $comp->ee_add(connection => sub {"here"});
$comp->ee_remove($ref);
The name of the event will be checked using C<ee_events>, which should be implemented by class and return a list of available names
Don't use in the event (or weaken ref if you need to use it)
=head2 ee_remove_current
$comp->ee_add(
connection => sub($self) {
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
misc/devel-trace.pl view on Meta::CPAN
use strict;
use warnings;
use Scalar::Util qw/weaken/;
use Devel::StackTrace;
my $trace;
my $obj = bless {} => 'Some::package';
misc/devel-trace.pl view on Meta::CPAN
shift @args;
fn0(@args);
}
sub fn2 {
weaken($obj2);
fn1(@_);
}
my $ref = 'referenced';
fn2(5, 'ztring', $obj, \$ref, \&fn0, [], {}, $obj2);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Exception/Base.pm view on Meta::CPAN
*_qualify_to_ref = sub ($;) { no strict 'refs'; \*{ $_[0] } };
};
};
# Use weaken ref on stack if available
BEGIN {
eval {
require Scalar::Util;
my $ref = \1;
Scalar::Util::weaken($ref);
};
if (not $@) {
*_HAVE_SCALAR_UTIL_WEAKEN = sub () { !! 1 };
}
else {
lib/Exception/Base.pm view on Meta::CPAN
and are the arguments of called function. Collected if the verbosity on
throwing exception was greater than 1. Contains only the first element of
caller stack if the verbosity was lower than 3.
If the arguments of called function are references and
C<L<Scalar::Util>::weaken> function is available then reference is weakened.
eval { Exception::Base->throw( message=>"Message" ); };
($package, $filename, $line, $subroutine, $hasargs, $wantarray,
$evaltext, $is_require, @args) = $@->caller_stack->[0];
lib/Exception/Base.pm view on Meta::CPAN
next if ! defined $Isa_Package{$c[0]} ? $Isa_Package{$c[0]} = do { local $@; local $SIG{__DIE__}; eval { $c[0]->isa(__PACKAGE__) } } : $Isa_Package{$c[0]};
# Collect the caller stack
my @args = @DB::args;
if (_HAVE_SCALAR_UTIL_WEAKEN) {
foreach (@args) {
Scalar::Util::weaken($_) if ref $_;
};
};
my @stacktrace_element = ( @c[0 .. 7], @args );
push @caller_stack, \@stacktrace_element;
# Collect only one entry if verbosity is lower than 3 and skip ignored packages
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Exception/Reporter/Summarizer.pm view on Meta::CPAN
Carp::confess("register_reporter called, but a reporter was already registered")
if $self->{reporter};
$self->{reporter} = $reporter;
Scalar::Util::weaken($self->{reporter});
return;
}
sub reporter { $_[0]->{reporter} }
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Spiffy.pm view on Meta::CPAN
" return \$_[0]->{%s} = do { my \$self = \$_[0]; %s }\n" .
" unless \$#_ > 0 or defined \$_[0]->{%s};\n",
weak_init =>
" return do {\n" .
" \$_[0]->{%s} = do { my \$self = \$_[0]; %s };\n" .
" Scalar::Util::weaken(\$_[0]->{%s}) if ref \$_[0]->{%s};\n" .
" \$_[0]->{%s};\n" .
" } unless \$#_ > 0 or defined \$_[0]->{%s};\n",
return_if_get =>
" return \$_[0]->{%s} unless \$#_ > 0;\n",
set =>
" \$_[0]->{%s} = \$_[1];\n",
weaken =>
" Scalar::Util::weaken(\$_[0]->{%s}) if ref \$_[0]->{%s};\n",
sub_end =>
" return \$_[0]->{%s};\n}\n",
);
sub field {
inc/Spiffy.pm view on Meta::CPAN
local *paired_arguments = sub { (qw(-package -init)) };
Spiffy->parse_arguments(@_);
};
my ($field, $default) = @values;
$package = $args->{-package} if defined $args->{-package};
die "Cannot have a default for a weakened field ($field)"
if defined $default && $args->{-weak};
return if defined &{"${package}::$field"};
require Scalar::Util if $args->{-weak};
my $default_string =
( ref($default) eq 'ARRAY' and not @$default )
inc/Spiffy.pm view on Meta::CPAN
}
$code .= sprintf $code{set_default}, $field, $default_string, $field
if defined $default;
$code .= sprintf $code{return_if_get}, $field;
$code .= sprintf $code{set}, $field;
$code .= sprintf $code{weaken}, $field, $field
if $args->{-weak};
$code .= sprintf $code{sub_end}, $field;
my $sub = eval $code;
die $@ if $@;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Exporter/Extensible.pm view on Meta::CPAN
);
$sigil_to_generator_prefix{''}= $sigil_to_generator_prefix{'&'};
our %ord_is_sigil= ( ord '$', 1, ord '@', 1, ord '%', 1, ord '*', 1, ord '&', 1, ord '-', 1, ord ':', 1 );
our %ord_is_directive= ( ord '-', 1, ord ':', 1 );
my ($carp, $croak, $weaken, $colon, $hyphen);
$carp= sub { require Carp; $carp= \&Carp::carp; goto $carp; };
$croak= sub { require Carp; $croak= \&Carp::croak; goto $croak; };
$weaken= sub { require Scalar::Util; $weaken= \&Scalar::Util::weaken; goto $weaken; };
$colon= ord ':';
$hyphen= ord '-';
sub import {
my $self= shift;
lib/Exporter/Extensible.pm view on Meta::CPAN
# Then pass that list to the installer (or uninstaller)
$self->$method(\@flat_install);
# If scope requested, create the scope-guard object
if (my $scope= $self->{scope}) {
$$scope= bless [ $self, \@flat_install ], 'Exporter::Extensible::UnimportScopeGuard';
$weaken->($self->{scope});
}
# It's entirely likely that a generator might curry $self inside the sub it generated.
# So, we end up with a circular reference if we're holding onto the set of all things we
# exported. Clear the set.
%$install= ();
view all matches for this distribution
view release on metacpan or search on metacpan
t/01-xtags.t view on Meta::CPAN
use strict;
use warnings;
no warnings 'once', 'redefine';
use Test::More;
use List::Util qw(pairs unpairs);
use Scalar::Util 'weaken';
use Data::Printer;
use Exporter::Handy::Util xtags => { -as => 'xtags_standard' };
use Exporter::Handy::Util xtags => { -as => 'xtags_prefixed', sig => ':' };
view all matches for this distribution
view release on metacpan or search on metacpan
lib/ExtUtils/Builder/Planner.pm view on Meta::CPAN
sub _create_callback {
my ($self, $add_to) = @_;
return undef unless $add_to;
my $this = $self;
Scalar::Util::weaken($this);
return sub {
my ($entry) = @_;
$this->create_phony($add_to, $entry);
};
}
view all matches for this distribution
view release on metacpan or search on metacpan
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
use vars qw(@ISA @EXPORT_OK $VERSION @EXPORT_FAIL);
require Exporter;
require List::Util; # List::Util loads the XS
@ISA = qw(Exporter);
@EXPORT_OK = qw(blessed dualvar reftype weaken isweak tainted readonly openhandle refaddr isvstring looks_like_number set_prototype);
$VERSION = "1.23";
$VERSION = eval $VERSION;
unless (defined &dualvar) {
# Load Pure Perl version if XS not loaded
require Scalar::Util::PP;
Scalar::Util::PP->import;
push @EXPORT_FAIL, qw(weaken isweak dualvar isvstring set_prototype);
}
sub export_fail {
if (grep { /dualvar/ } @EXPORT_FAIL) { # no XS loaded
my $pat = join("|", @EXPORT_FAIL);
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
require Carp;
Carp::croak("$err is only available with the XS version of Scalar::Util");
}
}
if (grep { /^(weaken|isweak)$/ } @_ ) {
require Carp;
Carp::croak("Weak references are not implemented in the version of perl");
}
if (grep { /^(isvstring)$/ } @_ ) {
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
Scalar::Util - A selection of general-utility scalar subroutines
=head1 SYNOPSIS
use Scalar::Util qw(blessed dualvar isweak readonly refaddr reftype tainted
weaken isvstring looks_like_number set_prototype);
# and other useful utils appearing below
=head1 DESCRIPTION
C<Scalar::Util> contains a selection of subroutines that people have
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
If EXPR is a scalar which is a weak reference the result is true.
$ref = \$foo;
$weak = isweak($ref); # false
weaken($ref);
$weak = isweak($ref); # true
B<NOTE>: Copying a weak reference creates a normal, strong, reference.
$copy = $ref;
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
Return true if the result of EXPR is tainted
$taint = tainted("constant"); # false
$taint = tainted($ENV{PWD}); # true if running under -T
=item weaken REF
REF will be turned into a weak reference. This means that it will not
hold a reference count on the object it references. Also when the reference
count on that object reaches zero, REF will be set to undef.
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
prevent the object being DESTROY-ed at its usual time.
{
my $var;
$ref = \$var;
weaken($ref); # Make $ref a weak reference
}
# $ref is now undef
Note that if you take a copy of a scalar with a weakened reference,
the copy will be a strong reference.
my $var;
my $foo = \$var;
weaken($foo); # Make $foo a weak reference
my $bar = $foo; # $bar is now a strong reference
This may be less obvious in other situations, such as C<grep()>, for instance
when grepping through a list of weakened references to objects that may have
been destroyed already:
@object = grep { defined } @object;
This will indeed remove all references to destroyed objects, but the remaining
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
=over
=item Weak references are not implemented in the version of perl
The version of perl that you are using does not implement weak references, to use
C<isweak> or C<weaken> you will need to use a newer release of perl.
=item Vstrings are not implemented in the version of perl
The version of perl that you are using does not implement Vstrings, to use
C<isvstring> you will need to use a newer release of perl.
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
C<Scalar::Util> contains both perl and C implementations of many of its functions
so that those without access to a C compiler may still use it. However some of the functions
are only available when a C compiler was available to compile the XS version of the extension.
At present that list is: weaken, isweak, dualvar, isvstring, set_prototype
=back
=head1 KNOWN BUGS
bundled/Scalar-List-Utils/Scalar/Util.pm view on Meta::CPAN
Copyright (c) 1997-2007 Graham Barr <gbarr@pobox.com>. All rights reserved.
This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.
Except weaken and isweak which are
Copyright (c) 1999 Tuomas J. Lukka <lukka@iki.fi>. All rights reserved.
This program is free software; you can redistribute it and/or modify it
under the same terms as perl itself.
view all matches for this distribution
view release on metacpan or search on metacpan
t/01-vector_of_vectors/src/ppport.h view on Meta::CPAN
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_resetpvn|||
sv_reset|||
sv_rvweaken||5.006000|
sv_sethek|||
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
view all matches for this distribution
view release on metacpan or search on metacpan
examples/Object-WithIntAndString/ppport.h view on Meta::CPAN
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Extism/ppport.h view on Meta::CPAN
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Extorter.pm view on Meta::CPAN
Memoize::memoize
Scalar::Util::blessed
Scalar::Util::refaddr
Scalar::Util::reftype
Scalar::Util::weaken
);
=head1 DESCRIPTION
view all matches for this distribution
view release on metacpan or search on metacpan
lib/FAST/Bio/SeqFeature/Gene/GeneStructure.pm view on Meta::CPAN
package FAST::Bio::SeqFeature::Gene::GeneStructure;
use vars qw($WeakRefs);
use strict;
BEGIN {
eval "use Scalar::Util qw(weaken);";
if ($@) {
$FAST::Bio::SeqFeature::Gene::GeneStructure::WeakRefs = 0;
} else { $FAST::Bio::SeqFeature::Gene::GeneStructure::WeakRefs = 1; }
}
lib/FAST/Bio/SeqFeature/Gene/GeneStructure.pm view on Meta::CPAN
unless( exists $self->{'_transcripts'} ) {
$self->{'_transcripts'} = [];
}
$self->_expand_region($fea);
if( $FAST::Bio::SeqFeature::Gene::GeneStructure::WeakRefs ) {
$fea->parent(weaken $self);
} else {
$fea->parent($self);
}
push(@{$self->{'_transcripts'}}, $fea);
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/FCGI/EV/Std.pm view on Meta::CPAN
use utf8;
use Carp;
our $VERSION = 'v2.0.1';
use Scalar::Util qw( weaken );
use if $INC{'CGI.pm'}, 'CGI::Stateless';
use constant HTTP_417_EXPECTATION_FAILED =>
lib/FCGI/EV/Std.pm view on Meta::CPAN
server => $server,
env => $env,
stdin => q{},
allow => $len <= $MAX_STDIN,
}, $class;
weaken($self->{server});
return $self;
}
# No protection against reading STDIN larger than CONTENT_LENGTH - because
# FastCGI protocol FORBID this so web server shouldn't send so much data
lib/FCGI/EV/Std.pm view on Meta::CPAN
$server->stdout($data, $is_eof) method (if $server is still defined - it
may become undef if connection to web server related to this CGI request
was already closed). In addition, FCGI::EV::Std may be configured to call
any user function, say, main::hup($server) if connection to web server will
be closed before CGI sent it reply. WARNING! User shouldn't keep
non-weaken() references to $server in it code!
See also L<FCGI::EV::Std::Nonblock> - it's helper module which make
writing non-blocking CGI ease.
Use these global variables to configure FCGI::EV::Std:
view all matches for this distribution
view release on metacpan or search on metacpan
lib/FCGI/EV.pm view on Meta::CPAN
use utf8;
use Carp;
our $VERSION = 'v2.0.1';
use Scalar::Util qw( weaken );
use IO::Stream;
use constant FCGI_HEADER_LEN => 8;
use constant FCGI_VERSION_1 => 1;
lib/FCGI/EV.pm view on Meta::CPAN
wait_for => IN|EOF,
cb => $self,
Wait_header => 1,
Need_in => FCGI_HEADER_LEN,
});
weaken($self->{io});
# It MAY have sense to add timeout between read() calls and timeout for
# overall time until EOF on STDIN will be received. First timeout
# can be about 3 minutes for slow clients, second can be about 4 hours
# for uploading huge files.
return;
lib/FCGI/EV.pm view on Meta::CPAN
When FCGI::EV object receive initial part of CGI request (environment
variables) it will call $handler_class->new() to create handler object
which should process that CGI request.
Parameter $server is FCGI::EV object itself. It's required to send CGI
reply. WARNING! Handler may keep only weaken() reference to $server!
After calling new() FCGI::EV object ($server) will continue receiving
STDIN content from web server and will call $handler->stdin() each time it
get next part of STDIN.
lib/FCGI/EV.pm view on Meta::CPAN
There no error-handling code in this example, see L<FCGI::EV::Std> for
more details.
package FCGI::EV::ExampleHandler;
use Scalar::Util qw( weaken );
use CGI::Stateless; # needed to re-init CGI.pm state between requests
sub new {
my ($class, $server, $env) = @_;
my $self = bless {
server => $server,
env => $env,
stdin => q{},
}, $class;
weaken($self->{server});
return $self;
}
sub stdin {
my ($self, $stdin, $is_eof) = @_;
view all matches for this distribution
view release on metacpan or search on metacpan
sv_ref||5.015004|
sv_replace|||
sv_report_used|||
sv_resetpvn|||
sv_reset|||
sv_rvweaken||5.006000|
sv_sethek|||
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
view all matches for this distribution
view release on metacpan or search on metacpan
include/ppport.h view on Meta::CPAN
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_ref||5.015004|
sv_replace|||
sv_report_used|||
sv_resetpvn|||
sv_reset|||
sv_rvweaken||5.006000|
sv_sethek|||
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
view all matches for this distribution
view release on metacpan or search on metacpan
lib/FSA/Rules.pm view on Meta::CPAN
table => {},
self => $self,
};
# Weaken the circular reference.
Scalar::Util::weaken $fsa->{self};
$params->{state_class} ||= 'FSA::State';
$params->{state_params} ||= {};
while (@_) {
my $state = shift;
lib/FSA/Rules.pm view on Meta::CPAN
$fsa->{table}{$state} = $obj;
push @{$fsa->{ord}}, $obj;
$states{$obj} = $def;
# Weaken the circular reference.
Scalar::Util::weaken $def->{machine};
}
# Setup rules. We process the table a second time to catch invalid
# references.
while (my ($key, $obj) = each %{$fsa->{table}}) {
lib/FSA/Rules.pm view on Meta::CPAN
exec => $exec,
message => $message,
};
# Weaken the circular reference.
Scalar::Util::weaken $rules[-1]->{state};
}
$def->{rules} = \@rules;
} else {
$def->{rules} = [];
}
view all matches for this distribution
view release on metacpan or search on metacpan
sv_release_COW|||
sv_release_IVX|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.006000||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.006000||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Feersum/Runner.pm view on Meta::CPAN
use EV;
use Feersum;
use Socket qw/SOMAXCONN/;
use POSIX ();
use Scalar::Util qw/weaken/;
use Carp qw/carp croak/;
use File::Spec::Functions 'rel2abs';
use constant DEATH_TIMER => 5.0; # seconds
use constant DEATH_TIMER_INCR => 2.0; # seconds
lib/Feersum/Runner.pm view on Meta::CPAN
return $_[0]->{endjinn}->request_handler($_[1]);
}
sub run {
my $self = shift;
weaken $self;
$self->{quiet} or warn "Feersum [$$]: starting...\n";
$self->_prepare();
my $app = shift || delete $self->{app};
lib/Feersum/Runner.pm view on Meta::CPAN
return;
}
sub _fork_another {
my ($self, $slot) = @_;
weaken $self;
my $pid = fork;
croak "failed to fork: $!" unless defined $pid;
unless ($pid) {
EV::default_loop()->loop_fork;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Fey/Column.pm view on Meta::CPAN
use warnings;
use namespace::autoclean;
our $VERSION = '0.44';
use Scalar::Util qw( blessed weaken );
use Fey::Column::Alias;
use Fey::Exceptions qw( param_error object_state_error );
use Fey::Literal;
use Fey::Table;
view all matches for this distribution