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

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

[Octave-bug-tracker] [bug #36743] Octave:language-extension warning warn


From: Lachlan Andrew
Subject: [Octave-bug-tracker] [bug #36743] Octave:language-extension warning warns about Octave's own files
Date: Wed, 16 Sep 2015 01:00:31 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36

Follow-up Comment #7, bug #36743 (project octave):

@Mike, the reason I said "syntactically" is that I was aware of the
distinction that Carnë was making, and wanting to separate behavioural issues
from syntactic ones. In particular, I was thinking of automatic broadcasting,
which really bugs me.  That needs to be a separate warning (as it was in 3.8,
IIRC).

Most of my use of Octave is for lists rather than true vectors.  If I add a
1xn to an nx1, I want either to get an n-dimensional vector, or an error.  I
don't want to get a matrix, which causes an error in an unrelated line of
code.  What is my solution?  Turn on "warning("Octave:language-extension")". 
Then I get inundated with errors.  Even if I didn't, it would preclude the
many useful Octave extensions, like +=, ++, (A+B)(10), which are syntactically
different and so presumably intentional.

It would be very easy to have a "systempath" variable, and exclude static
syntax checking for all files read from that path.  This only needs to affect
the parser.

@Carnë, I can see a case for getting rid of the option.  However, the
overhead of checking syntax is only incurred when the file is parsed -- when
it is first read in -- not every time it is executed.  (Try turning the
warning on, and watch it appear only when a new code path is executed.)

    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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