In <[EMAIL PROTECTED]>, Richard Soderberg writes:
:Artur noted that weakened refs were getting incremented refcnts. Looks like
:we forgot to tell sv.c about weakrefs. Here's a patch.
[...]
: case SVt_RV:
: SvANY(dstr) = new_XRV();
:- SvRV(dstr) = sv_dup_inc(SvRV(sstr));
:+ SvRV(dstr) = SvWEAKREF(sv_dup(SvRV(sstr)))
:+ ? sv_dup_inc(SvRV(sstr))
:+ : sv_dup(SvRV(sstr));
Are you sure that shouldn't be something like:
SvRV(dstr) = SvWEAKREF(SvRV(sstr)) ? ...
? As written it doesn't look right, though I haven't checked in detail.
(And similarly for the other cases.)
Hugo