Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

Re: Core module: Attribute::Handlers behaviour

by enigma (Novice)
on Oct 21, 2012 at 12:36 UTC ( #1000217=note: print w/replies, xml ) Need Help??

in reply to Core module: Attribute::Handlers behaviour

There was two issues that I have found.

1. I need to use strict 'refs';

2. Dump of args passed to ATTR is -

$VAR1 = 'Module'; $VAR2 = 'ANON'; $VAR3 = sub { "DUMMY" }; $VAR4 = 'TRACE'; $VAR5 = undef; $VAR6 = 'BEGIN';


Why it is taking "new()" as anonymous subroutine?

I think because of this only *{$_[1]} is not getting replaced with other sub... Please advise


Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1000217]
[Lady_Aleena]: File::Find doesn't have a simple sub wanted example, like get the name of the file.
[Discipulus]: there is also find2perl with your perl installation
[Discipulus]: and in the wanted sub you just calculate the duretion and add it the total, stop
[shmem]: sub wanted { push @files, $File::Find::name if $File::Find::name =~/\.mp3$/ }
[Lady_Aleena]: shmem, that is understandable! The two examples in File::Find don't make sense to me on a quick glance.

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (13)
As of 2017-04-23 20:50 GMT
Find Nodes?
    Voting Booth?
    I'm a fool:

    Results (432 votes). Check out past polls.