in reply to Re: Perl5 Internal Representation of string variable
in thread Perl5 Internal Representation of string variable

re: ". . .bytes in memory terminated by a x00 byte. "

In 'C' => 'YES', in Perl => 'want to know???'

Either perl has a count of characters for variable or some other mechanism to determine the size of the variable that contains a group of bytes. Can't use x00 as terminator, since perl wonderfully allows x00 to be a valid byte.

  • Comment on Re^2: Perl5 Internal Representation of string variable

Replies are listed 'Best First'.
Re^3: Perl5 Internal Representation of string variable
by Marshall (Canon) on Oct 02, 2010 at 17:52 UTC
    Yes, indeed,
    my $string = "asdf \x00 some more";
    print $string;
    does print past the asdf. So, a Perl string does know "how big it is".