[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: override display() for class
From: |
John W. Eaton |
Subject: |
Re: override display() for class |
Date: |
Mon, 13 Dec 2010 13:53:43 -0500 |
On 13-Dec-2010, bpabbott wrote:
| I wrote a simple class with display() overloaded. Both Octave and
| Matlab return "ans" for inputname(1) if there is no RHS variable.
I see the following behavior:
octave:3> function f (x)
> inputname (1)
> end
octave:4> f (1+2)
ans =
octave:5> x = 1; f (x)
ans = x
so if an expression is passed to F, inputname (1) returns an empty
string. Looking at the definition of inputname, I don't see how it
ever returns "ans".
jwe
- Re: override display() for class, (continued)
- Re: override display() for class, CdeMills, 2010/12/10
- RE: override display() for class, Steve White, 2010/12/10
- RE: override display() for class, CdeMills, 2010/12/10
- RE: override display() for class, Steve White, 2010/12/11
- Re: override display() for class, Jaroslav Hajek, 2010/12/12
- RE: override display() for class, Steve White, 2010/12/12
- Re: override display() for class, CdeMills, 2010/12/13
- Re: override display() for class, Ben Abbott, 2010/12/13
- Re: override display() for class, John W. Eaton, 2010/12/13
- Re: override display() for class, bpabbott, 2010/12/13
- Re: override display() for class,
John W. Eaton <=
- Re: override display() for class, bpabbott, 2010/12/13
- Re: override display() for class, John W. Eaton, 2010/12/13
- RE: override display() for class, Steve White, 2010/12/15