bugGNU Octave - Bugs: bug #44864, lazy_index produces error with...

 
 

bug #44864: lazy_index produces error with printf("%i")

Submitted by:  Martin Kunz <mkunz>
Submitted on:  Fri 17 Apr 2015 02:26:44 PM UTC  
 
Category: InterpreterSeverity: 5 - Blocker
Priority: 5 - NormalItem Group: Regression
Status: FixedAssigned to: None
Originator Name: Open/Closed: Closed
Release: 4.0.0Operating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

(Jump to the original submission Jump to the original submission)

Tue 02 Jun 2015 04:48:12 PM UTC, comment #7:

Retagging release from 4.0.0-rc3 to 4.0.0.

John W. Eaton <jwe>
Project Administrator
Sat 25 Apr 2015 05:29:14 PM UTC, comment #6:

Works for me. Closing report.

Rik <rik5>
Project Administrator
Sat 25 Apr 2015 05:18:57 PM UTC, comment #5:

I checked in the following changeset:

http://hg.savannah.gnu.org/hgweb/octave/rev/0d56160e346d

John W. Eaton <jwe>
Project Administrator
Sat 25 Apr 2015 05:06:57 PM UTC, comment #4:

Rik: I think it is the right thing to do. The lazy_index class is only supposed to be an optimization. If the index weren't "lazy" then the value would be a 1-based index array.

John W. Eaton <jwe>
Project Administrator
Sat 25 Apr 2015 05:29:17 AM UTC, comment #3:

The patch is very close. It no longer errors out, but the indices are off by 1; They are zero-based rather than one-based.

We could always add 1 to the result of fast_elem_extract(), but I suspect that is not the right thing to do.

Rik <rik5>
Project Administrator
Sat 25 Apr 2015 03:52:55 AM UTC, comment #2:

Something like the attached patch should fix this problem.

(file #33779)

John W. Eaton <jwe>
Project Administrator
Fri 17 Apr 2015 03:49:01 PM UTC, comment #1:

Confirmed. The printf family of routines was overhauled between 3.8.2 and 4.0.0. and this bug must have been introduced.

Rik <rik5>
Project Administrator
Fri 17 Apr 2015 02:26:44 PM UTC, original submission:

Hi,

I stumbled upon a strange error which I could track to a line like this:

In Octave 3.8.2 the result is

as I would expect. In 4.0.0-rc3 I get

In both cases the type returned by find is lazy_index

but it seems that this type is not properly treated by printf in 4.0.0-rc3.

Martin Kunz <mkunz>

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #33779:  diffs.txt added by jwe (954B - text/plain)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by jwe (Updated the item)
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by rik5
  • -unavailable- added by mkunz (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 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 02 Jun 2015 04:48:12 PM UTCjweRelease4.0.0-rc3=>4.0.0
    Sat 25 Apr 2015 05:29:14 PM UTCrik5StatusConfirmed=>Fixed
      Open/ClosedOpen=>Closed
    Sat 25 Apr 2015 03:52:55 AM UTCjweAttached File-=>Added diffs.txt, #33779
    Fri 17 Apr 2015 06:41:41 PM UTCrik5Severity3 - Normal=>5 - Blocker
    Fri 17 Apr 2015 03:49:01 PM UTCrik5StatusNone=>Confirmed
      Operating SystemMicrosoft Windows=>Any
      Carbon-Copy-=>Added jwe

    Back to the top


    Powered by Savane 3.1-cleanup1