bugGNU Octave - Bugs: bug #30923, OO code failing under 3.3.52+

 
 

bug #30923: OO code failing under 3.3.52+

Submitted by:  Pascal Dupuis <cdemills>
Submitted on:  Tue 31 Aug 2010 04:48:37 PM UTC  
 
Category: InterpreterSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Incorrect Result
Status: InvalidAssigned to: Jaroslav Hajek <highegg>
Originator Name: Pascal DupuisOpen/Closed: Closed
Release: devOperating System: GNU/Linux

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

Wed 01 Sep 2010 03:01:08 PM UTC, comment #4:

Yes, that is precisely the problem. This is basically a design flaw in Matlab; it should have been sth like subsnumel() first and only call numel() as a default.

Jaroslav Hajek <highegg>In charge of this item.
Wed 01 Sep 2010 01:06:25 PM UTC, comment #3:

MatLab numel is misleading:
numel(randn(3)) returns 9
numel(some object with many data) returns 1

The documentation states that it may be used explicitely or implicitely, associated to a call to subsref/subsasgn. Unfortunately, from inside numel, you just can't distinguish both uses. My workaround is just NOT to provide an overloaded numel for dataframe.

Regards

Pascal

Pascal Dupuis <cdemills>
Project Member
Wed 01 Sep 2010 11:10:23 AM UTC, comment #2:

Sorry, I was confused by those two reports. However, this is not a bug in Octave, but rather in the dataframe package. Octave is right to gripe here because numel() indicates that x.rownames should produce a cs-list (of length 70):

Effectively, this is a design defect of Matlab and there is no way around it. If you want x.rownames = [] to work, then numel(x) must return 1.

octave:1> x=dataframe('data_test.csv');
octave:2> numel(x)
ans = 70

Jaroslav Hajek <highegg>In charge of this item.
Wed 01 Sep 2010 08:40:35 AM UTC, comment #1:

I pulled rev 10936, and the problem is NOT fixed. Could you please re-open this bug ?

Regards

Pascal

Pascal Dupuis <cdemills>
Project Member
Tue 31 Aug 2010 04:48:37 PM UTC, original submission:

Context: install the dataframe package from octave-forge.

Under 3.2.4, the following code works OK:
x=dataframe('octave_frame/data_test.csv');
x.rownames = [];

Under latest from hg:
- the first line works as bug 30909 is fixed
- the second fails with
'Invalid assignment to cs-list outside multiple assignment"

Under 3.2.4, the assignment is performed by @dataframe/subasgn.m. Under 3.3.52+, said code is not called.

Regards

Pascal

Pascal Dupuis <cdemills>
Project Member

 

(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 highegg (Updated the item)
  • -unavailable- added by cdemills (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 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 01 Sep 2010 11:10:23 AM UTChigheggItem GroupSegfault, Bus Error, etc.=>Incorrect Result
      StatusFixed=>Invalid
    Wed 01 Sep 2010 07:21:21 AM UTChigheggStatusNone=>Fixed
      Assigned toNone=>highegg
      Open/ClosedOpen=>Closed

    Back to the top


    Powered by Savane 3.1-cleanup1