* Dave Mitchell <davem@iabyn.com> [2015-04-25T06:25:34] > On Fri, Apr 24, 2015 at 11:16:23PM -0700, Gabor Szabo wrote: > > In earlier versions of perl if AUTOLOAD is defined in a module but DESTROY > > is not defined, the AUTOLOAD would be executed when the object goes out of > > scope and one would have had to add an empty DESTROY to eliminate the > > problem caused by this. > > [...] > The change bisects to this, which leads to the suspicion that it was > unintended. > > commit 8c34e50dccefe2a0539ba2339a2889bb841986c2 That does look unintended. I don't see discussion of the change on p5p or changes to tests, either. I know I've added special casing to AUTOLOADs to skip DESTROY, which makes me feel certain that people have used AUTOLOAD to handle DESTROY. Sure, it's been broken for three years now, but unless there is a compelling reason against it, I think we should restore this behavior and add a regression test. The downside is breaking code only ever written or tested on 5.18.0, or later. In other words, we'd be fixing a regression introduced before the earliest supported version of perl. Still, I think it should be fixed. -- rjbsThread Previous