Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Pushing anon hash on to HoA structure giving Use of uninitialized value in hash element error using warnings

by mrpeabody (Friar)
on Jul 05, 2004 at 05:25 UTC ( [id://371777]=note: print w/replies, xml ) Need Help??


in reply to Pushing anon hash on to HoA structure giving Use of uninitialized value in hash element error using warnings

I'm assuming this statement is where the error is occurring, since it's the only push() in your code.

push( @{$bros->{$year}}, $info);

There are three variables there, and Perl is telling you that one of them is undefined. You should be able to tell which one by looking at the code, but if not some judiciously placed print() statements will help. (Hint: it's the one that only gets initialized in one branch of a conditional.)

  • Comment on Re: Pushing anon hash on to HoA structure giving Use of uninitialized value in hash element error using warnings
  • Download Code

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2024-04-24 01:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found