Dan Sugalski writes:
: At 12:59 PM + 3/28/02, Piers Cawley wrote:
: >Wouldn't it be nice if you could do:
: >
: >class Foo {
: > ...
: >
: > &{intern('{}')} := method ($self: $key) is lvalue {
: > ...
: > }
: >}
: >
: >So, later, you could do:
: >
: >$obj = Foo.new;
: >
: >
At 12:59 PM + 3/28/02, Piers Cawley wrote:
>Wouldn't it be nice if you could do:
>
>class Foo {
> ...
>
> &{intern('{}')} := method ($self: $key) is lvalue {
> ...
> }
>}
>
>So, later, you could do:
>
>$obj = Foo.new;
>
>$obj{something} = $something_else;
>
>ie, overriding
Simon Cozens <[EMAIL PROTECTED]> writes:
> Piers Cawley:
>> ie, overriding hash lookups, array lookups, whatever.
>
> Ah, you want C#/Python indexers, you do. So do I.
Um... is that what you call 'em. Actually, you can already do
'use overload q|%{}|', to sort of do this...
--
Piers
"It i
Piers Cawley:
> ie, overriding hash lookups, array lookups, whatever.
Ah, you want C#/Python indexers, you do. So do I.
--
"If that makes any sense to you, you have a big problem."
-- C. Durance, Computer Science 234