develooper Front page | perl.perl5.porters | Postings from May 2008

Re: thoughts about overloading method calls

Thread Previous | Thread Next
From:
Ævar Arnfjörð Bjarmason
Date:
May 6, 2008 19:53
Subject:
Re: thoughts about overloading method calls
Message ID:
51dd1af80805061953k7098a786ub40180fed528e5ec@mail.gmail.com
On 5/6/08, Ricardo SIGNES <perl.p5p@rjbs.manxome.org> wrote:
>   a) what does ref return?

The return value could not make sense since the class would not be
anonymous, or it would have to return something like "ARRAY" which
would be worse.

>   b) how do I set up operator overloading?

You couldn't, I guess.

> Doing this with blessed-into-code seems a bit more convoluted.

Indeed, I really hadn't thought it through:)

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