Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Desperatly seeking CSW (Class::Std Wisdom)

by stvn (Monsignor)
on Aug 08, 2006 at 14:08 UTC ( #566167=note: print w/replies, xml ) Need Help??


in reply to Desperatly seeking CSW (Class::Std Wisdom)

Without a peice of code which exhibits the issue, it is hard to say what exactly is causing it. However, I can tell you that this error:

Can't make anonymous subroutine cumulative at <blah>
is coming from inside Class::Std (the &_find_sub routine to be exact) and is called from the &initialize method, which is called within the perl compiler's CHECK phase. Most of what it is doing here is building restricted (aka - protected), private, cummulative and anticumulative methods. From the code you show above, I see nothing related to these things, and I suspect it is being caused by some other bit of code.

-stvn
  • Comment on Re: Desperatly seeking CSW (Class::Std Wisdom)

Replies are listed 'Best First'.
Re^2: Desperatly seeking CSW (Class::Std Wisdom)
by krisahoch (Deacon) on Aug 08, 2006 at 14:52 UTC

    stvn,

    That is a good point. I can't believe I overlooked showing an example of the call that I am making.

    my $state_arguments = { 'form_data' => \%form_data }; my $state_manager = My::Class->new($state_arguments); my $welcome_handler = { 'trigger' => 'welcome', 'handler' => 'Handler::Welcome', }; $state_manager->register_handler($welcome_handler);
    That is when I get the error message.

      I am not getting the same error when I run this code:

      Which seems to confirm my suspicion that the problem is elsewhere in your class. The error you are tripping in Class::Std is in one of the (IMHO) darker corners of the module. Something as simple as what you have demonstrated in the OP should not be causing that error. Perhaps if you posted your entire class, the issue might be more obvious to spot.

      -stvn

        stvn,

        I figured out what was going on. Originally I was calling all of these methods from a web-based script. The server cached one of these temp files and that is where the problem has been. I actually solved this particular issue along time ago. When I went and did what you did (command-line script) the problem disappeared. It also prompted me to get a Apache Reboot as well. Thank you for your time.

        Kristofer

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://566167]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2022-06-29 05:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My most frequent journeys are powered by:









    Results (94 votes). Check out past polls.

    Notices?