|XP is just a number|
return of hash-assigment in list context (bug?)by LanX (Abbot)
|on Jan 02, 2013 at 13:38 UTC||Need Help??|
LanX has asked for the
wisdom of the Perl Monks concerning the following question:
(EDIT: for a simplified bug-demo see update further down and onliner post)
For Re: Syntax explanation required I tried to show the elimination of duplicates when assigning a list of two hashes to a third hash.
But while the third hash holds the correct results (line 105) the return value (line 102) of the assignment looks very weird, and I can't really explain whats happening.
to be sure that it's not just my repl showing buggy results I reproduced it again on the console:
I'm still suffering from a little hangover from recent tumultuous events ... ;-)
So please could someone tell me what I am missing here?
I was able to further isolate whats happening to a simple list assignment:
seems like that the fact that duplicated keys are eliminated (here a) somehow confuses the returned value.