octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #47631] ind2sub with empty dimension vector


From: Lachlan Andrew
Subject: [Octave-bug-tracker] [bug #47631] ind2sub with empty dimension vector
Date: Mon, 11 Apr 2016 08:03:26 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0

Update of bug #47631 (project octave):

                Severity:              3 - Normal => 2 - Minor              
                Priority:              5 - Normal => 3 - Low                
                 Release:                   4.0.0 => dev                    

    _______________________________________________________

Follow-up Comment #3:

Mike, are you suggesting closing this with "won't fix"?

Rik, I don't quite follow your example.  Your comments after the example seem
to apply to


x = [];
[i,j] = ind2sub ([0, 0], 3)      % <-- [0, 0] = size (x)
% Now what do the following do in Matlab?
x(3)
x(i,j)


rather than the example you gave.  As Mike pointed out, [] is not the size of
any valid matrix.

To me, the question is whether or not handling [] in this way may allow a user
to avoid a "special case" check in some context.  If so, there is value in
handling it the way Matlab does.

Unfortunately the original poster didn't leave an email, so we'll never know
where this came up.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?47631>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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