bugGNU Octave - Bugs: bug #56320, [octave forge] (generate_html)...

 
 

bug #56320: [octave forge] (generate_html) literal '%' in 1st line produces failure

Submitter:  Juan Pablo Carbajal <juanpi>
Submitted:  Tue 14 May 2019 12:52:13 AM UTC
   
 
Category:  Octave Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Unexpected Error or Warning
Status:  Confirmed Assigned to:  None
Originator Name:  juanpi Open/Closed:  * Open
Release:  * other Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Post a Comment

Add a New Comment Rich Markup
   

Discussion

Tue 14 May 2019 01:41:14 AM UTC, comment #1: 


>  This makes the package fails with matlab style docstrings.


Just a small correction, this bug has nothing to do with whether '#' or '%' comment markers are used for the doc string. This has to do with a literal '%' in the doc string text itself.

So this does not trigger this bug


function myfunc ()
%MYFUNC This is a simple function.
%
% This function does something.
...


But this does trigger this bug


function myfunc ()
%MYFUNC This is a 100% Simple function.
%
% This function does something.
...


specifically because '% S' is not a valid printf conversion specifier. If it was a lower-case 's' it would be interpreted as '% s', which is valid, but of course silently buggy in a different way.

Mike Miller <mtmiller>
Group Member
Tue 14 May 2019 12:52:13 AM UTC, original submission:  

This report is based on all the information provided by Mike Miller, thanks!

When the first help sentence of a function contains a literal '%' character, generate_html fails when parsing the docstring.

A simple test case would be


    ## -*- texinfo -*-
    ## @deftypefn {} {} myfunc
    ## This function is 10% ready.
    ## @end deftypefn
    function myfunc ()
    endfunction


This makes the package fails with matlab style docstrings.

Juan Pablo Carbajal <juanpi>
Group Member

 

Attached Files

This item currently has no attached files.

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

Attach Files:
   
   
Comment:
   

 

Dependencies

This item does not depend on any other items.

No items depend on this one.

 

Mail Notification Carbon-Copy List

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

    Votes

    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.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

    History

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-05-14 mtmiller StatusNone Confirmed

    Back to the top

    Powered by Savane 3.16-598c.
    Corresponding source code