develooper Front page | perl.perl5.porters | Postings from October 2001

Re: Clamp, wherefor art thou

Thread Previous | Thread Next
Jarkko Hietaniemi
October 30, 2001 08:11
Re: Clamp, wherefor art thou
Message ID:
> It's the patches to the core that I'm really after getting accepted, since
> once they're in, anyone can have their own interface. So, for this patch,
> I just hacked up an interface so that I could test things (the test suite
> has over 1,300 tests).
> The functionality is the main interest at this stage:
>   Scalar & Hash:
>     * can make readonly
>     * can remove readonlyness
>     * can inspect the readonlyness
>  (A readonly hash may not have keys added or deleted, or any value changed)
>   Clamping Hashes:
>     * can clamp a hash's keys:
>         May not add/delete keys -- a subset of a readonly hash
>     * can clamp access on non-approved keys:
>         May not reference non-approved keys. "Approved keys" are keys that
>         exist when a hash's access is clamped. You can then delete() them
>         if you don't really want them in your hash, but want to allow them.
> The functionality is exported by Readonly.xs, and provided to the user via
> Again, my implementation of the latter is just an example.
> (Its docs are near the head of the patch, for easy perusal).
> As it's too early at this stage for pod/* changes, none are included.
> I'd really love to see this in the core, since I wish for this type of
> functionality every day that I use perl (which is every day).
>         Jeffrey

I think the basic idea of the functionality is okay-- but I also think
the implementation details still need some more discussion.  I see Tim
already had some concerns, and I think NI-S had some more in the past.

$jhi++; #
        # There is this special biologist word we use for 'stable'.
        # It is 'dead'. -- Jack Cohen

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