From: Yves Junqueira Date: Tue, 7 Aug 2012 03:40:43 +0000 (-0700) Subject: text/template: fix range example. X-Git-Tag: go1.1rc2~2683 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=b3caa2ba3ca1591f7545a78c0010103ad8376409;p=gostls13.git text/template: fix range example. R=r CC=adg, gobot, golang-dev https://golang.org/cl/6449096 --- diff --git a/src/pkg/text/template/doc.go b/src/pkg/text/template/doc.go index aa50ab97f6..4a1682d97a 100644 --- a/src/pkg/text/template/doc.go +++ b/src/pkg/text/template/doc.go @@ -198,7 +198,7 @@ If a "range" action initializes a variable, the variable is set to the successive elements of the iteration. Also, a "range" may declare two variables, separated by a comma: - $index, $element := pipeline + range $index, $element := pipeline in which case $index and $element are set to the successive values of the array/slice index or map key and element, respectively. Note that if there is