Tcl Source Code

Artifact [093be90503]
Login

Artifact 093be90503c20d043d37cd6919d4e49c58cefa8aa4d561d37c382de8f73fb127:

Attachment "expr.n.patch" to ticket [fa5e5add02] added by anonymous 2021-08-30 14:05:23. (unpublished)
diff -ur doc.old/expr.n doc/expr.n
--- doc.old/expr.n	2021-08-30 16:10:06.135149971 +0300
+++ doc/expr.n	2021-08-30 16:26:55.550127908 +0300
@@ -409,6 +409,14 @@
 When the expression is unbraced to allow the substitution of a function or
 operator, consider using the commands documented in the \fBmathfunc\fR(n) or
 \fBmathop\fR(n) manual pages directly instead.
+.PP
+Some tips:
+.RS
+.TP 7
+\fBValue negation\fR
+.
+\fBset a [expr {-$a}]\fR is faster than \fBset a [expr {$a * -1}]\fR.
+.RE
 .SH EXAMPLES
 .PP
 Define a procedure that computes an