bugGNU Octave - Bugs: bug #56927, textscan format '%q' does not...

 
 

bug #56927: textscan format '%q' does not produce Matlab-compatible results for corner case where pattern fails

Submitter:  Rik <rik5>
Submitted:  Fri 20 Sep 2019 06:58:40 PM UTC
 
Category:  Octave Function Severity:  2 - Minor
Priority:  1 - Later Item Group:  Matlab Compatibility
Status:  Confirmed Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment (Rich Markup)
   

Comment Type & Canned Response:
       

 

Fri 20 Sep 2019 06:58:40 PM UTC, original submission:  

Sample code to reporduce

textscan ('"a,b","c"trailing', '%q', 'delimiter', ',')
ans =
{
  [1,1] =
  {
    [1,1] = a,b
    [2,1] = c
    [3,1] = trailing
  }

}

In Matlab, there are only two outputs, not three, and the second output is "ctrailing".  In other words, the section of text not matching the pattern, but occurring before a delimiter, is appended to the last format match.

This is an obscure corner case and I am merely noting it, rather than suggesting it get fixed.

Rik <rik5>
Project Administrator

 

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

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only project members can vote.

     

     

     

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-09-20 rik5 Priority5 - Normal 1 - Later

    Back to the top

    Powered by Savane 3.10