in reply to Re^4: Internals question.
in thread Internals question.

Perl assumes that it can call free() or realloc() on PVXs with impunity. This prevents many useful "tricks".

- tye        

Replies are listed 'Best First'.
Re^6: Internals question.
by BrowserUk (Patriarch) on Jul 23, 2007 at 18:54 UTC

    Yes. I realise that I would have to pre-allocate the array and make sure that neither the array (length), nor the scalar (at all) is mutated.

    I'd probably set them read-only using Internals::SetReadOnly() to assist in ensuring that. I realise that probably isn't foolproof. But it's just and experiment.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.