bugGNU Octave - Bugs: bug #33520, isequal does not behave properly...

 
 

bug #33520: isequal does not behave properly with empty structures

Submitted by:  Arnaud Delorme <arnodelorme>
Submitted on:  Sat 11 Jun 2011 04:31:05 AM UTC  
 
Category: InterpreterSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Incorrect Result
Status: Wont FixAssigned to: None
Originator Name: Open/Closed: Closed
Release: 3.4.0Operating System: Mac OS

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sun 12 Jun 2011 07:54:31 PM UTC, comment #3:

I think Octave should require the dimensions to agree in order to consider two values equal, so I am marking this as "won't fix" and closing this report.

OTOH, if this behavior of Matlab is described somewhere in the Matlab documentation, then point me to the precise location where it is documented and reopen this report.

John W. Eaton <jwe>
Project Administrator
Sat 11 Jun 2011 03:20:23 PM UTC, comment #2:

Matlab considers that both matrices are empty and considers them as equal. I agree that this is a tough call.

Arnaud Delorme <arnodelorme>
Sat 11 Jun 2011 06:34:42 AM UTC, comment #1:

Why should 0x0 and 1x0 matrices be considered equal? They don't have equal dimensions.

John W. Eaton <jwe>
Project Administrator
Sat 11 Jun 2011 04:31:05 AM UTC, original submission:

a = [];
b = zeros(1,0);

>> isequal(a, b)

ans = 0

>> isequal([], [])

ans = 1

Arnaud Delorme <arnodelorme>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by jwe (Posted a comment)
  • -unavailable- added by arnodelorme (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 12 Jun 2011 07:54:31 PM UTCjweItem GroupSegfault, Bus Error, etc.=>Incorrect Result
      StatusNone=>Wont Fix
      Open/ClosedOpen=>Closed

    Back to the top


    Powered by Savane 3.1-cleanup1