From 8a8cf5bf6d233c97180a6ef7e64d9c67a402470f Mon Sep 17 00:00:00 2001 From: Mihai Borobocea Date: Fri, 6 Sep 2019 20:30:51 +0300 Subject: [PATCH] text/template: refer to sorted map keys as "ordered" not "comparable" in docs Consistent with the spec's definition of "ordered" and "comparable". Fixes #34147 Change-Id: Id13186df5343588d80eaebfeb23092596a846d51 Reviewed-on: https://go-review.googlesource.com/c/go/+/193840 Reviewed-by: Ian Lance Taylor Reviewed-by: Rob Pike --- src/text/template/doc.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/text/template/doc.go b/src/text/template/doc.go index dbffaa4958..22266143a6 100644 --- a/src/text/template/doc.go +++ b/src/text/template/doc.go @@ -102,8 +102,8 @@ data, defined in detail in the corresponding sections that follow. If the value of the pipeline has length zero, nothing is output; otherwise, dot is set to the successive elements of the array, slice, or map and T1 is executed. If the value is a map and the - keys are of basic type with a defined order ("comparable"), the - elements will be visited in sorted key order. + keys are of basic type with a defined order, the elements will be + visited in sorted key order. {{range pipeline}} T1 {{else}} T0 {{end}} The value of the pipeline must be an array, slice, map, or channel. -- 2.50.0