with 5.8.2, 5.8.1 and 5.6.1 (and presumably 5.6.2 etc) > perl -MScalar::Util=weaken -e '$a=\"h";weaken($a)' Modification of a read-only value attempted at -e line 1 this means that if you're writing something general that weakens refs, like a cache, you have to do eval { local $SIG{__DIE__}; weaken($a); }; instead of just weaken ($a) Patch attached to fix this by adding PERL_MAGIC_backref to the list of things that can be done to a readonly value. I added some tests, everything still passes, is there some other reason not to allow this? F P.S. I sent this to perlbug initially but it never made the list (I think due to me sending a followup before the ticket was approved).