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

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

[Octave-bug-tracker] [bug #32182] data loss in hierarchical objects


From: Volkmar Glauche
Subject: [Octave-bug-tracker] [bug #32182] data loss in hierarchical objects
Date: Wed, 19 Jan 2011 21:03:47 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; de; rv:1.9.2.13) Gecko/20101206 Ubuntu/10.10 (maverick) Firefox/3.6.13

URL:
  <http://savannah.gnu.org/bugs/?32182>

                 Summary: data loss in hierarchical objects
                 Project: GNU Octave
            Submitted by: glauche
            Submitted on: Mi 19 Jan 2011 21:03:46 GMT
                Category: None
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Incorrect Result
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: dev
        Operating System: GNU/Linux

    _______________________________________________________

Details:

I have got a hierarchy of object classes:
baseobj
derivobj  - derived from baseobj
deriv2obj - derived from derivobj

baseobj and derivobj define a method manipulate(). In baseobj, this method
assigns a random number to the .val property. In derivobj/deriv2obj, it calls
a manipulate() method on each member of a cell array .val. While manipulate()
operates correctly on derivobj objects, it crashes on deriv2obj objects:


d1 = derivobj;
d1.val = {baseobj baseobj};
d1m = manipulate(d1);
d2 = deriv2obj;
d2.val = {baseobj baseobj};
d2m = manipulate(d2);
error: manipulate: A(I): index out of bounds; value 2 out of bound 1
error: called from:
error:   /home/volkmar/octave/@derivobj/manipulate.m at line 6, column 26


The error occurs in the for loop in @derivobj/manipulate, when trying to
access the .val field entries in a deriv2obj. The same code works perfectly
for derivobj objects. 




    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Mi 19 Jan 2011 21:03:46 GMT  Name: deriv2obj.tgz  Size: 3kB   By:
glauche

<http://savannah.gnu.org/bugs/download.php?file_id=22459>

    _______________________________________________________

Reply to this item at:

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

_______________________________________________
  Nachricht geschickt von/durch Savannah
  http://savannah.gnu.org/




reply via email to

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