Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: "print" of nonexistent element is actually altering a hash (updated)

by AnomalousMonk (Archbishop)
on Feb 17, 2020 at 19:37 UTC ( #11113071=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    c:\@Work\Perl\monks>perl -wMstrict -MData::Dump -le
    "my %hash;
    ...
     dd \%hash;
    "
    { www => { xxx => { yyy => {} } } }
    
  2. or download this
    c:\@Work\Perl\monks>perl -wMstrict -MData::Dump -le
    "no autovivification;
    ...
     dd \%hash;
    "
    {}
    
  3. or download this
    c:\@Work\Perl\monks>perl -wMstrict -MData::Dump -le
    "my %h;
    ...
      "access in aliased (lvalue) context",
      { www => { xxx => { yyy => { zzz => undef } } } },
    )
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (3)
As of 2022-12-05 07:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?