in reply to Re^5: can I change hash keys or values directly
in thread can I change hash keys or values directly

> but the calculated array-index for the linked list containing that particular key can change based upon the size of the hash

Well yes, but in the case when the hash-table is doubled, the whole internal data is overhauled anyway and effectively a new hash is created.

The old linked lists can't be reused. (At least I don't see how this could be done, the collisions need to be reduced by using the new slots)

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery

  • Comment on Re^6: can I change hash keys or values directly

Replies are listed 'Best First'.
Re^7: can I change hash keys or values directly
by Marshall (Canon) on Feb 05, 2021 at 09:13 UTC
    Yes, quite correct.