in reply to Re^4: 5.24 -> 5.28 -- what has changed in autovivification?
in thread 5.24 -> 5.28 -- what has changed in autovivification?
I've found:
The documentation for the exists operator no longer says that autovivification behaviour "may be fixed in a future release". We've determined that we're not going to change the default behaviour. perl #127712I understand that there are only two options:
I hoped to find solution that doesn't autovifify when existence is checked, so I could just act like this if (exists $h{a}{b}{c}{d}) { ... } and not like this if (exists $h{a} && exists $h{a}{b} && exists $h{a}{b}{c} && exists $h{a}{b}{c}{d}) { ... }
My preferred default behaviour would be to return undef for $h{a}{b}{c}{d} and NOT create $h{a}, $h{a}{b}, $h{a}{b}{c}... This is not possible.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: 5.24 -> 5.28 -- what has changed in autovivification?
by haukex (Archbishop) on Apr 18, 2020 at 22:08 UTC | |
by leszekdubiel (Scribe) on Apr 19, 2020 at 22:35 UTC | |
|
Re^6: 5.24 -> 5.28 -- what has changed in autovivification?
by choroba (Cardinal) on Apr 18, 2020 at 21:44 UTC |