octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #47908] Octave:classdef-to-struct not shown by


From: Lachlan Andrew
Subject: [Octave-bug-tracker] [bug #47908] Octave:classdef-to-struct not shown by warning_ids.m
Date: Sat, 14 May 2016 00:14:15 +0000 (UTC)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0

Follow-up Comment #3, bug #47908 (project octave):

As I posted to Octave-Maintainers recently, I'd like to overhaul the warning
system.

One of the changes would be to have an enumeration of all warnings in the
Octave: namespace in an enumeration.  This would mean that C code can throw
warnings with a cost independent of the number of disabled IDs.  That will
allow more fine-grained control over which language features a user wants to
be warned about (my pet peeve being automatic broadcast).

The efficiency will become more important if we allow multiple scopes, such as
"this directory", "this file", "this function", "all functions called by this
function" (currently called "local"), as well as global -- as suggested at bug
#36743 and bug #47687.)

The enumeration would be auto-generated from warning_ids.m, and so keeping
that file in sync would be easier.  Of course, .m files would still use string
IDs, and so could get out of sync.  However, it would be simple to have a tool
to grep for IDs in one but not the other.

Although anyone can make up their own IDs, user warnings shouldn't be in the
Octave: namespace.  I'd suggest that Octave Forge should also have its own
namespace, but that may involve unnecessary incompatibility.

Note that  lastwarn ()  is only useful if one type of warning is given.  The
alternative is to do what Matlab does, and list the ID when the warning is
printed.  Octave currently has an unused flag for verbose warnings.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?47908>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]