mirror of
https://github.com/golang/go
synced 2024-09-15 22:20:06 +00:00
doc/go1.18: note short-circuit and/or in html/template
It was already noted in text/template; copied from there. Change-Id: Ie749d04004af60f2333073ddf556ff7e16c81c45 Reviewed-on: https://go-review.googlesource.com/c/go/+/379794 Trust: Russ Cox <rsc@golang.org> Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Emmanuel Odeke <emmanuel@orijtech.com> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
8cfbb58bc7
commit
c8b0dcea4a
|
@ -571,7 +571,7 @@ Do not send CLs removing the interior tags from such phrases.
|
||||||
|
|
||||||
<p><!-- CL 323318, CL 332771 -->
|
<p><!-- CL 323318, CL 332771 -->
|
||||||
<a href="/pkg/bytes/#Trim"><code>Trim</code></a>, <a href="/pkg/bytes/#TrimLeft"><code>TrimLeft</code></a>,
|
<a href="/pkg/bytes/#Trim"><code>Trim</code></a>, <a href="/pkg/bytes/#TrimLeft"><code>TrimLeft</code></a>,
|
||||||
and <a href="/pkg/bytes/#TrimRight"><code>TrimRight</code></a> are now allocation free and, especially for
|
and <a href="/pkg/bytes/#TrimRight"><code>TrimRight</code></a> are now allocation free and, especially for
|
||||||
small ASCII cutsets, up to 10 times faster.
|
small ASCII cutsets, up to 10 times faster.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
@ -759,6 +759,14 @@ Do not send CLs removing the interior tags from such phrases.
|
||||||
new <code>{{continue}}</code> command will immediately start the
|
new <code>{{continue}}</code> command will immediately start the
|
||||||
next loop iteration.
|
next loop iteration.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
<p><!-- CL 321490 -->
|
||||||
|
The <code>and</code> function no longer always evaluates all arguments; it
|
||||||
|
stops evaluating arguments after the first argument that evaluates to
|
||||||
|
false. Similarly, the <code>or</code> function now stops evaluating
|
||||||
|
arguments after the first argument that evaluates to true. This makes a
|
||||||
|
difference if any of the arguments is a function call.
|
||||||
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
</dl><!-- html/template -->
|
</dl><!-- html/template -->
|
||||||
|
|
||||||
|
@ -938,7 +946,7 @@ Do not send CLs removing the interior tags from such phrases.
|
||||||
|
|
||||||
<p><!-- CL 323318, CL 332771 -->
|
<p><!-- CL 323318, CL 332771 -->
|
||||||
<a href="/pkg/strings/#Trim"><code>Trim</code></a>, <a href="/pkg/strings/#TrimLeft"><code>TrimLeft</code></a>,
|
<a href="/pkg/strings/#Trim"><code>Trim</code></a>, <a href="/pkg/strings/#TrimLeft"><code>TrimLeft</code></a>,
|
||||||
and <a href="/pkg/strings/#TrimRight"><code>TrimRight</code></a> are now allocation free and, especially for
|
and <a href="/pkg/strings/#TrimRight"><code>TrimRight</code></a> are now allocation free and, especially for
|
||||||
small ASCII cutsets, up to 10 times faster.
|
small ASCII cutsets, up to 10 times faster.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue