Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Fun with Hook::LexWrap and code instrumentation

by adrianh (Chancellor)
on Mar 14, 2003 at 07:36 UTC ( [id://242974] : perlmeditation . print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
        package Foo;
    
    ...
        
        sub todo { shift->{todo} };
        sub done { shift->{done} };
    
  2. or download this
        package Bar;
        use base qw(Foo);
    ...
                $from->{todo}--;
            };
        };
    
  3. or download this
    # Monitor the arguments of subroutines ...
    my $monitor = monitor_arg
    ...
            warn "removed item not added to done list in $subroutine\n"
                if $removed > 0 && $removed != $done;
        };
    
  4. or download this
    use Carp;
    use Storable qw(dclone);
    ...
        };
        return \@wrappers;
    };
    
  5. or download this
    my $o = Bar->new;
    $o->add;
    ...
    $from->add;
    my $to = Ni->new;
    $to->naughty_transfer($from);
    
  6. or download this
    removed item not added to done list in Bar::naughty_remove
    removed item not added to done list in Ni::naughty_transfer