bugGNU Octave - Bugs: bug #49434, which returns "built-in...

 
 

bug #49434: which returns "built-in function" for classdef m-file

Submitted by:  Rik <rik5>
Submitted on:  Tue 25 Oct 2016 04:00:58 AM UTC  
 
Category:  Octave Function Severity:  3 - Normal
Priority:  5 - Normal Item Group:  None
Status:  None Assigned to:  None
Originator Name:  Open/Closed:  Open
Release:  dev Operating System:  Any

Add a New Comment (Rich Markup)
   

You are not logged in

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

 

Fri 19 Apr 2019 05:22:40 AM UTC, comment #5: 

>> which datetime
/opt/…/matlab/timefun/@datetime/datetime.m  % datetime constructor

Mike Miller <mtmiller>
Project Administrator
Thu 18 Apr 2019 08:18:08 PM UTC, comment #4: 

Hmm, I just assumed that those were classdef .m files.  So instead, what happens when we really do have a classdef .m file?  If there is something simple like

classdef myclass
end

in a file called myclass.m in the path, what does "which myclass" report?

John W. Eaton <jwe>
Project Administrator
Thu 18 Apr 2019 07:25:31 PM UTC, comment #3: 

Running online, I get

inputParser is a built-in method  % inputParser constructor

containers.Map says the same thing.

Rik <rik5>
Project Administrator
Thu 18 Apr 2019 06:12:45 PM UTC, comment #2: 

What does Matlab display for

which inputParser

?

Does it just show the path to the .m file (I assume there is one) or does it also print a message like Octave does with something like "inputParser is the classdef file found in:..."?

John W. Eaton <jwe>
Project Administrator
Thu 08 Dec 2016 08:24:58 PM UTC, comment #1: 

+1 I saw this problem as well.

Also of note:

>> which inputParser
'inputParser' is a built-in function

>> __which__ inputParser
ans =

  scalar structure containing the fields:

    name = inputParser
    file =
    type = built-in function

>> file_in_loadpath inputParser.m
ans = C:\Octave\4.2.0\share\octave\4.2.0\m\general\inputParser.m

Amro <amro_octave>
Tue 25 Oct 2016 04:00:58 AM UTC, original submission:  

This probably hints at somethin deeper, but which() returns the wrong answer for a classdef file like inputParser.

octave:1> which inputParser
'inputParser' is a built-in function

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

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by amro_octave (Posted a comment)
  • -email is unavailable- added by rik5 (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-04-25 mtmiller Dependencies- => bugs #50875 is dependent

    Back to the top


    Powered by Savane 3.5