"A. Pagaltzis" <[EMAIL PROTECTED]> writes: > * Steffen Schwigon <[EMAIL PROTECTED]> [2006-05-24 13:55]: >> "A. Pagaltzis" <[EMAIL PROTECTED]> writes: >> > * Martin Kjeldsen <[EMAIL PROTECTED]> [2006-05-24 12:25]: >> >> I understand this as the hash entry with key 'array' get >> >> assigned a array consisting of $count number multiplied by >> >> $scale. If that is right, we must be modifying $arg_for >> >> (%buckets) since we are adding an entry to the hash. >> > >> > $arg_for is a reference to a hash. The hash is modified, but >> > not the reference to it. >> >> It's probably an unimplemented/buggy feature of Pugs. > > Err I think you misread my mail. I meant that the code modifies > the hash, but does nothing to modify the reference, so there is > no need to make the reference read-write.
In my understanding, the '->' makes an alias to the elements of the hash, which is different from being a reference. And the "is rw" modifies that alias (the loop element). You are right, in that the "is rw" shouldn't be needed because the loop element alias should be "rw" by default. Which in turn it isn't, because of the pugs bug. That's I think why the discussed problem and the pugsbug could be related. Steffen -- Steffen Schwigon <[EMAIL PROTECTED]> Dresden Perl Mongers <http://dresden-pm.org/>