bugGNU Octave - Bugs: bug #41011, scalar indexed assignment should...

 
 

bug #41011: scalar indexed assignment should cast input type

Submitted by:  Felipe G. Nievinski <fgnievinski>
Submitted on:  Fri 27 Dec 2013 03:34:14 AM UTC  
 
Category: InterpreterSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Matlab Compatibility
Status: ConfirmedAssigned to: None
Originator Name: Open/Closed: Open
Release: devOperating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

Fri 25 Nov 2016 10:50:15 PM UTC, comment #2:

This bug is still present in Octave 4.2.0.

Hartmut <hardy>
Sat 28 Dec 2013 07:26:50 PM UTC, comment #1:

Confirmed on the development branch as well.

An example of Octave getting it right is the use of 'single' or 'uint8'.

The same behavior should hold for class logical, but fails

Rik <rik5>
Project Administrator
Fri 27 Dec 2013 03:34:14 AM UTC, original submission:

In Octave:

octave:8> temp = [true, false]; temp(1) = 0; class(temp)
ans = logical
octave:9> temp = true; temp(1) = 0; class(temp)
ans = double
octave:10> temp = true; temp(2) = 0; class(temp)
ans = double

In Matlab:

>> temp = [true, false]; temp(1) = 0; class(temp)

ans =
logical

>> temp = true; temp(1) = 0; class(temp)

ans =
logical

>> temp = true; temp(2) = 0; class(temp)

ans =
logical

Felipe G. Nievinski <fgnievinski>

 

(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 hardy (Posted a comment)
  • -unavailable- added by mtmiller (Updated the item)
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by fgnievinski (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
    Thu 31 Mar 2016 05:36:30 AM UTCmtmillerOperating SystemMicrosoft Windows=>Any
    Sat 28 Dec 2013 07:26:50 PM UTCrik5StatusNone=>Confirmed
      Release3.6.4=>dev

    Back to the top


    Powered by Savane 3.1-cleanup1