in reply to Re: DBD::mysql Unusual Behavior
in thread DBD::mysql Unusual Behavior
The second one causes autovivification since you're actually extending some pseudo-predefined structure. You can't dereference an undefined value, so it just makes one up for you.use Data::Dumper; my $foo = {}; 1 if (defined($foo->{bar})); print Dumper($foo); 1 if (defined($foo->{bar}->{baz})); print Dumper($foo);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re^2: DBD::mysql Unusual Behavior
by bart (Canon) on Aug 23, 2002 at 20:13 UTC | |
by tadman (Prior) on Aug 23, 2002 at 20:39 UTC |