help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Speedup/Refaktoring loop? Extended...


From: John W. Eaton
Subject: Re: Speedup/Refaktoring loop? Extended...
Date: Wed, 27 Aug 2008 12:09:02 -0400

On 27-Aug-2008, Andreas Romeyke wrote:

| Thanks for your explanation. But I did not see the reason, why the
| transpose-operator and the transpose function will be evaluated
| differently? Should it not be the same in internal representation of
| Octaves's interpreter? I thought Octave uses an AST to walk on it?

Yes, but for historical reasons, operators are handled internally by
the interpreter and function calls are handled differently.  The
interpreter does not currently translate .' to a call to the transpose
function.  However, I think this may need to change to properly handle
operator overloading for classes.  For example, so you can define an
@double/transpose.m function to overload the behavior of the transpose
operator with your own function (of course, doing that will be slow,
so I don't guess you speed demons care about that too much, right?).

jwe


reply via email to

[Prev in Thread] Current Thread [Next in Thread]