[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #65876] error retrieving data from struct valu
From: |
John W. Eaton |
Subject: |
[Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps |
Date: |
Thu, 13 Jun 2024 10:40:57 -0400 (EDT) |
Follow-up Comment #4, bug #65876 (group octave):
The trouble seems to be due to this block of code in octave_classdef::subsref
in ov-classdef.cc:
// If the number of output arguments is unknown, attempt to set up
// a proper value for nargout at least in the simple case where the
// cs-list-type expression - i.e., {} or ().x, is the leading one.
if (nargout <= 0)
{
bool maybe_cs_list_query = (type[0] == '.' || type[0] == '{'
|| (type.length () > 1 && type[0] ==
'('
&& type[1] == '.'));
if (maybe_cs_list_query)
{
// Set up a proper nargout for the subsref call by calling
numel.
octave_value_list tmp;
int nout;
if (type[0] != '.') tmp = idx.front ();
nout = xnumel (tmp);
if (nargout != 0 || nout > 1)
nargout = nout;
}
else if (nargout < 0)
nargout = 1;
}
that was added in changeset
https://hg.savannah.gnu.org/hgweb/octave/rev/554a932fc6d0 in an attempt to fix
bug #63841.
Although there were some new tests committed for that bug in changeset
https://hg.savannah.gnu.org/hgweb/octave/rev/768df05d04f3, none of them fail
if I comment out the above code block *and* the example code from this bug
report works again. I don't understand the point of the above code block.
What problem was it trying to fix?
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?65876>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, A.R. Burgers, 2024/06/13
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, A.R. Burgers, 2024/06/13
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, A.R. Burgers, 2024/06/13
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, John W. Eaton, 2024/06/13
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps,
John W. Eaton <=
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/13
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/13
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/14
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, John W. Eaton, 2024/06/14
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, A.R. Burgers, 2024/06/14
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/14
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/14
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/16
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, A.R. Burgers, 2024/06/20
- [Octave-bug-tracker] [bug #65876] error retrieving data from struct values in containers.Maps, Markus Mützel, 2024/06/20