in reply to Re: Data structure challenge
in thread Data structure challenge

Yes, Perl has to initialize all array elements. Internally, it will store pointers (to SV's), and if Perl wouldn't initialize the array elements, it ends up with random memory addresses, and it has no way of finding out whether the element was initialized or not.

Abigail

Replies are listed 'Best First'.
Re: Re: Data structure challenge
by bsb (Priest) on Mar 23, 2004 at 04:37 UTC
    As I thought about it, I began to suspect that.

    XS of course doesn't count.
    Does this cover virtually programming in C via syscall(&SYS_mmap,..) and pack-ing data structures?

    Otherwise, I give up. In fact, I give up anyway, I'm not going near syscall.