You're making the same mistake I (and others) made. That of assuming that newSVrv() creates a new RV that points to the SV passed to it as an argument. It doesn't.
The documentation for the call reads:
newSVrvCreates a new SV for the RV, rv, to point to. If rv is not an RV then it will be upgraded to one. If classname is non-null then the new SV will be blessed in the specified package. The new SV is returned and its reference count is 1.
In reply to Re: SV creation inside XS
by BrowserUk
in thread SV creation inside XS
by llancet
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |