develooper Front page | perl.perl5.porters | Postings from February 2003

scalar question...

Thread Next
Brandon Willis
February 18, 2003 02:39
scalar question...
Message ID:
How does perl know where the end of a scalar that has a char array
attached is?  If I manually do a SvCUR_set(sv,strlen(blah)) and
SvLEN_set(sv,strlen(blah)) to the exact length of the char array will
perl respect that?  Do I have to do a *SvEND(sv) = '\0'; to keep perl
from searching for the '\0' end of the string?

I guess my question is if both SvLEN and SvCUR are at the same position
(because I have created the scalar in C and outside the will of perl)
can I force it to respect those boundaries?


Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About