6.2.5 Usage of brackets
-----------------------

In SINGULAR, curly brackets ({ }) must
always be used to enclose the statement body following such constructs
like if, else, for, or while, even if this
block consists of only a single statement. Similarly, in the return
statement of a procedure, parentheses (( )) must
always be used to enclose the return value.  Even if there is no value
to return, parentheses have to be used after a return statement
(i.e., return();).  For example,

if (i == 1) return i;    // WRONG!!!!!

results in an error. Instead, it must be written as

if (i == 1) { return (i); }

<font size="-1">
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; User manual for <a href="http://www.singular.uni-kl.de/"><i>Singular</i></a> version 2-0-4, October 2002,
generated by <a href="http://www.gnu.org/software/texinfo/"><i>texi2html</i></a>.
</font>

</body>
</html>
