develooper Front page | perl.perl6.language | Postings from April 2002

classes, interfaces, properties and 'is'

Thread Next
From:
Melvin Smith
Date:
April 4, 2002 10:47
Subject:
classes, interfaces, properties and 'is'
Message ID:
5.1.0.14.2.20020404133053.02a01eb0@pop.mindspring.com
Reading Apoc and Exeg 4 I liked most everything. It has already
been said many times how Perl6 is finally getting features
the OO guys have been wanting forever, so I won't state the
obvious again, but I would like to propose an alternate keyword...

1) In Perl6 we can tag metadata properties to an object using the 'is' keyword.
2) Also, in Perl6 we can derive a new class from an ancestor using 'is'.
3) Thirdly, we can specify that the class is an 'interface'.

 From my understanding 'interface' is a keyword here. Fair enough.

I'd simply like to propose using 'has' for properties for 2 reasons:

1) The above is, to me, fuzzy to use it for all 3 of the cases.
2) 'has' is more intuitive for saying "This object _has_ this property".

Then, 'is' means something more tangible to me, such as the
item IS a Bird, or the item IS the Client interface.

I guess its all about linguistics, but thats what we are here for.

My personal feeling is the use of the keyword 'interface' is optional
just for clarity; I don't really care if we differentiate between a true object
and an interface but that gets off subject a bit.

If this has already been discussed, I wasn't paying attention. :)

-Melvin


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