Re: Debugger code does &SvIVX(...)
[email protected] (Dave Mitchell) Fri, 8 Apr 2005 15:01:53 +0100
| Newsgroups | perl.perl5.porters,perl.ponie.dev |
|---|---|
| Message-ID | <[email protected]> |
On Fri, Apr 08, 2005 at 02:20:56PM +0100, Nicholas Clark wrote: > Does anyone understand why/how the debugger code wants to save the value > of the IV slot inside an IV? Both are conditional on PERLDB_SUB_NN being > true: Presumably in the presence of PERLDB_SUB_NN, $DB::sub stores the address of the current CV rather than its name. The old value has to be saved so that on exit from the sub, the old value is retored. > Is doing this even legal? Can the SV * in question get upgraded further, and > thus that saved memory location stop being the location of SV's IV? Yes, looks highy illegal. > Should we add a new save type that takes the pointer to an SV and saves/ > restores the IV slot? Or maybe just use save_item() like the other branch does? -- In the 70's we wore flares because we didn't know any better. What possible excuse does the current generation have?