changeset 19131:cbd55a4e549b

update documentation for do_braindead_shortcircuit_evaluation (bug #43177)
author John W. Eaton <jwe@octave.org>
date Sun, 21 Sep 2014 14:40:39 -0400
parents 90421e725f1d
children c3bdd640a4dd
files doc/interpreter/expr.txi
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/doc/interpreter/expr.txi	Sun Sep 21 14:38:29 2014 -0400
+++ b/doc/interpreter/expr.txi	Sun Sep 21 14:40:39 2014 -0400
@@ -1009,10 +1009,10 @@
 
 @sc{matlab} has special behavior that allows the operators @samp{&} and
 @samp{|} to short-circuit when used in the truth expression for @code{if} and 
-@code{while} statements.  The Octave parser may be instructed to behave in the
-same manner, but its use is strongly discouraged.
-
-@DOCSTRING(do_braindead_shortcircuit_evaluation)
+@code{while} statements.  Octave also behaves the same way by default,
+though the use of the @samp{&} and @samp{|} operators in this way is
+strongly discouraged.  Instead, you should use the @samp{&&} and @samp{||}
+operators that always have short-circuit behavior.
 
 Finally, the ternary operator (?:) is not supported in Octave.  If
 short-circuiting is not important, it can be replaced by the @code{ifelse}