bugGNU Octave - Bugs: bug #33540, strmatch Matlab compatibility issue

 
 

bug #33540: strmatch Matlab compatibility issue

Submitter:  Arnaud Delorme <arnodelorme>
Submitted:  Sat 11 Jun 2011 03:47:11 PM UTC
   
 
Category:  None Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * 3.4.0 Operating System:  * Mac OS
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 09 Aug 2018 05:28:55 PM UTC, comment #3: 

This bug report is ancient, but because it was terrifically easy I changed strmatch to accept a cellstr as the first input here (https://hg.savannah.gnu.org/hgweb/octave/rev/e4f670d9df5c).

Rik <rik5>
Group administrator
Sun 17 Jul 2011 01:55:59 AM UTC, comment #2: 

This issue seems to be compatibility with an undocumented feature of Matlab.  In addition, the function in question is deprecated and set to be removed from Matlab.  Finally, the suggested replacement, strcmp, does accept cell arrays as the first argument.  For all of the above reasons, I think we won't choose to address this.

Rik <rik5>
Group administrator
Sat 11 Jun 2011 10:45:03 PM UTC, comment #1: 

As I understand the ML docs, the first argument to strmatch() should be a text string, not a (1x1) cell array.

IMO the fact that it works under ML seems an undocumented feature of ML rather than an incompatibility with Octave.

BTW I saw that strmatch() is to be dropped from future ML versions.

Philip Nienhuis <philipnienhuis>
Group Member
Sat 11 Jun 2011 03:47:11 PM UTC, original submission:  

strmatch cannot process cell array under Octave


strmatch({ 'a' }, { 'a' 'b' 'c' }, 'exact') 
% this works under Matlab but crashes under Octave

Arnaud Delorme <arnodelorme>

 

(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 (Posted a comment)
  • -email is unavailable- added by philipnienhuis (Posted a comment)
  • -email is unavailable- added by arnodelorme (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 group members can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-08-09 rik5 StatusWont Fix Fixed
    2011-07-17 rik5 StatusNone Wont Fix
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code