aboutsummaryrefslogtreecommitdiff
path: root/src/text
diff options
context:
space:
mode:
Diffstat (limited to 'src/text')
-rw-r--r--src/text/template/template.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/text/template/template.go b/src/text/template/template.go
index 41cdd5682c..1135d819b9 100644
--- a/src/text/template/template.go
+++ b/src/text/template/template.go
@@ -50,6 +50,10 @@ func (t *Template) Name() string {
// New allocates a new, undefined template associated with the given one and with the same
// delimiters. The association, which is transitive, allows one template to
// invoke another with a {{template}} action.
+//
+// Because associated templates share underlying data, template construction
+// cannot be done safely in parallel. Once the templates are constructed, they
+// can be executed in parallel.
func (t *Template) New(name string) *Template {
t.init()
nt := &Template{