help-octave
[Top][All Lists]
Advanced

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

silent_functions ignored?


From: John W. Eaton
Subject: silent_functions ignored?
Date: Wed, 15 Aug 2001 22:38:30 -0500

On 16-Aug-2001, Nathan <address@hidden> wrote:

| I'm new to octave, using 2.1.33 (the rpm which ships with RH7.1). I
| finally found the silent_functions variable, only it doesn't appear to
| make any difference. I tried setting it in my script, in the function
| module, in my ~/.octaverc. I can verrify that it has been set (to 1, if
| I try to set it to true I get 'preference of "true" is obsolete -- use
| numeric value of 1 instead'.
| 
| octave tells me that the variable is set to the desired value, but it
| won't suppress the noisy evaluations of every  line in my script.
| 
| Am I doing something wrong - surely I wouldn't be the first person to
| discover this if it were a bug. (I didn't see it in the archives.)

Hmm.  Works for me with 2.1.34:

  GNU Octave, version 2.1.34 (i386-pc-linux-gnu).
  Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 John W. Eaton.
  This is free software with ABSOLUTELY NO WARRANTY.
  For details, type `warranty'.

  *** This is a development version of Octave.  Development releases
  *** are provided for people who want to help test, debug, and improve
  *** Octave.
  ***
  *** If you want a stable, well-tested version of Octave, you should be
  *** using one of the stable releases (when this development release
  *** was made, the latest stable version was 2.0.16).

  octave2.1:1> function f () x = 1 endfunction
  octave2.1:2> f
  x = 1
  octave2.1:3> silent_functions = 1
  silent_functions = 1
  octave2.1:4> f
  octave2.1:5> 

But perhaps there is a bug, but it is only uncovered by a more
complicated example.  If so, please submit a complete report to the
bug-octave mailing list.

OTOH, silent_functions is probably not what you really want.  You
probably just want to end your statements that might print something
with a semicolon, like this:

  function f ()
    x = 1;
  endfunction

jwe



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

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