Preferences

That will not always pass.

if (exists $foo->{bar}){ .. will not run .. }

if ($foo->{bar}) {...}

if (exists $foo->{bar}){ .. will run .. }


That doesn't do any autovivification. You meant (note the referencing down a deeper level than the exists test):

if (exists $foo->{bar}){ .. will not run .. } if ($foo->{bar}->{baz}) {...} if (exists $foo->{bar}){ .. will run .. }

Can't believe I've had that wrong for so long. Must have misinterpreted it right when I learned perl and have always been careful about it.
I see, thank you.

I am certainly a perl novice.

This item has no comments currently.

Keyboard Shortcuts

Story Lists

j
Next story
k
Previous story
Shift+j
Last story
Shift+k
First story
o Enter
Go to story URL
c
Go to comments
u
Go to author

Navigation

Shift+t
Go to top stories
Shift+n
Go to new stories
Shift+b
Go to best stories
Shift+a
Go to Ask HN
Shift+s
Go to Show HN

Miscellaneous

?
Show this modal