bugGNU Octave - Bugs: bug #62803, help class.class: error when...

 
 

bug #62803: help class.class: error when accessing classdef ctor's help

Submitter:  Colin Macdonald <cbm>
Submitted:  Sun 24 Jul 2022 04:43:29 AM UTC
 
Category:  Classdef Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Unexpected Error or Warning
Status:  None 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:
       

 

Sun 31 Jul 2022 10:29:25 PM UTC, comment #1: 

Tracing the function calls for our MWE, it looks like the name "test_classdef.test_classdef" is just passed around for a long time. I don't have the expertise to really debug this, but hopefully a description of how it is passed around is at least helpful.

The help function is defined here
https://hg.savannah.gnu.org/hgweb/octave/file/e37e46ef0505/scripts/help/help.m

The error is during the call to get_help_text in line 103.

get_help_text is defined in https://hg.savannah.gnu.org/hgweb/octave/file/e37e46ef0505/libinterp/corefcn/help.cc at line 386

This in turn calls raw_help, defined in the same file at line 207

raw_help calls raw_help_from_symbol_table, defined at line 537

raw_help_from_symbol_table calls find_function, defined at line 249 in https://hg.savannah.gnu.org/hgweb/octave/file/e37e46ef0505/libinterp/corefcn/symtab.cc

find_function then calls find_function defined at line 277.

Up to this point, very little has been done except passing the name around.

Michael Bagherpour <bagelboy>
Sun 24 Jul 2022 04:43:29 AM UTC, original submission:  

Consider:

help test_classdef.test_classdef

error: unknown package 'test_classdef'
error: called from
    <unknown>

MWE: place the attached "test_classdef.m" inside a directory called "@test_classdef".

Expected results: the help for the constructor for the class.  That is, something different from "help test_classdef" (which correctly gives the class help).  MWE has different docstrings for each.

Today's tip.  Also on 6.4.0 (have not tested on 7.1.0) which gives the same:

help test_classdef.test_classdef
error: unknown package 'test_classdef'
error: called from
    <unknown>
    help at line 102 column 20

Colin Macdonald <cbm>

 

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

Attach Files:
   
   
Comment:
   

Attached Files
file #53469:  test_classdef.m added by cbm (939B - text/x-objcsrc - place inside @test_classdef folder)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bagelboy (Posted a comment)
  • -email is unavailable- added by cbm (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
    2022-07-24 cbm Attached File- Added test_classdef.m, #53469

    Back to the top


    Powered by Savane 3.9