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

Re: [PATCH for discussion] new feature: clamp %hash

Thread Previous | Thread Next
From:
Abigail
Date:
July 23, 2001 11:59
Subject:
Re: [PATCH for discussion] new feature: clamp %hash
Message ID:
20010723185651.8587.qmail@foad.org
On Mon, Jul 23, 2001 at 11:47:54AM -0700, Jeffrey Friedl wrote:
> 
> Abigail  <abigail@foad.org> wrote:
> |> The real underlaying problems here are 1) Perl doesn't have structs,
> |> but more importantly, 2) Perl only gives you one instance variable per
> |> object. Pseudo-hashes tried to fix the symptoms, not the cause and
> |> they didn't succeed. "clamp" tries to fix the symptoms too - and not
> |> the cause.
> 
> Assuming that Perl had perfect object-oriented mechanisms (however anyone
> wishes to define "perfect"), and in practice no one used hashes for
> objects, would you find no benefit for having readonly/clamped hashes?

Sure, it will have some benefit. But enough that it needs a change in
the language (while it also can be done with a simple tie)? I'm not
so sure about that. 



Abigail

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About