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

Re: Doubt in assigning hash reference values for Constant pragma declaration ?

by salva (Abbot)
on Sep 21, 2007 at 07:08 UTC ( #640284=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use constant A => $hash;
    
  2. or download this
    my $hash = { 'a' => 2 };
    
  3. or download this
    my $hash;
    BEGIN { $hash = { 'a' => 2 } }
    use constant A => $hash;
    
  4. or download this
    my $hash;
    use constant A => $hash = {'a' => 2};
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (3)
As of 2020-07-08 04:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?