[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #65116] classdef display override populates an
From: |
Rik |
Subject: |
[Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname |
Date: |
Thu, 4 Jan 2024 11:41:31 -0500 (EST) |
Update of bug#65116 (group octave):
Priority: 5 - Normal => 3 - Low
_______________________________________________________
Follow-up Comment #2:
This is definitely weird. The inputname() function, which does a lot of
voodoo, seems to be at the heart of it. I tried something slightly different
as I wondered if having the output of inputname() go directly into a variable
and then using that variable would change things. It didn't. Next I tried
eliminating the printf() entirely. This was even stranger as now the variable
'ans' is populated with whatever was in the output stream, in this case
"hello", rather than the name of the class.
classdef tc
methods
function a = tc()
#nothing to do
endfunction
function display(a)
str = inputname (1);
disp ('hello');
#printf (" %s = my test\n", str);
endfunction
endmethods
endclassdef
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?65116>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans whith class when using inputname, John Donoghue, 2024/01/03
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans whith class when using inputname, John Donoghue, 2024/01/04
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, Rik, 2024/01/04
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname,
Rik <=
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, John W. Eaton, 2024/01/04
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, Rik, 2024/01/04
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, Rik, 2024/01/04
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, John W. Eaton, 2024/01/05
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, Rik, 2024/01/05
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, John Donoghue, 2024/01/05
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, John W. Eaton, 2024/01/05
- [Octave-bug-tracker] [bug #65116] classdef display override populates ans with class when using inputname, Rik, 2024/01/05