bugGNU Octave - Bugs: bug #48090, warning ("query", ID)...

 
 

bug #48090: warning ("query", ID) returns a structure with undocumented fields

Submitted by:  Francesco Potortì <pot>
Submitted on:  Thu 02 Jun 2016 11:40:05 AM UTC  
 
Category:  Documentation Severity:  2 - Minor
Priority:  5 - Normal Item Group:  Documentation
Status:  Confirmed Assigned to:  None
Originator Name:  Open/Closed:  Open
Release:  4.0.2 Operating System:  Any

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

Tue 05 Jul 2016 04:51:52 PM UTC, comment #2:

After the help for 'query' add something like this:

'query' returns a struct with two fields:
- identifier, which is a string containing the ID name of the warning
- state, which is astring whose contents is one of 'on', 'off', 'error'

After the help for 'local' add something like this:

If you want to disable a warning only around some lines of code, using 'local' may be too coarse. In this case, you can write something along these lines:

prev = warning('query', 'Octave:divide-by-zero');
warning('off', 'Octave:divide-by-zero');
...
warning(prev.state, 'Octave:divide-by-zero');

Francesco Potortì <pot>
Wed 15 Jun 2016 08:08:02 AM UTC, comment #1:

When I run the command, I get a structure with two fairly self-explanatory fields:

If that is also what you get, and you would like more documentation, could you write a draft of the documentation you would like?

Is there some more information that you need in order to write the documentation?

Lachlan Andrew <lachlan>
Thu 02 Jun 2016 11:40:05 AM UTC, original submission:

Using the warning() function to query the status of a warning returns a structure which is completely undocumented

Francesco Potortì <pot>

 

(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 lachlan (Posted a comment)
  • -email is unavailable- added by mtmiller (Updated the item)
  • -email is unavailable- added by pot (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.

     

     

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-06-02 mtmiller CategoryInterpreter => Documentation
        Severity3 - Normal => 2 - Minor
        StatusNone => Confirmed
        Summaryquerying the status of a waringn returns an andocumented structure => warning ("query", ID) returns a structure with undocumented fields

    Back to the top


    Powered by Savane 3.3