Use the Devel::Peek module's Dump() function to inspect the various compartments within a scalar at whatever stage you wish in the script. Example:
use Devel::Peek; my $x = "99 bottles of beer on the wall"; Dump( $x ); $x += 1; Dump( $x ); $x .= "\n"; Dump( $x ); $x += 2; Dump( $x );
Have fun exploring what various actions do to your scalar internally. I can't remember where I read a good explanation of the internals of Perl's various data types. It might have been OReilly's Advanced Perl Programming... or it might not. Hopefully someone can help out with a good reference.
PS: To specifically answer the question; once Perl has recognized it in numeric context, it doesn't need to be re-'converted'.
Dave
In reply to Re: Question on SV internals
by davido
in thread Question on SV internals
by John M. Dlugosz
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |