]> Cypherpunks repositories - gostls13.git/commit
html/template, text/template: clarify template redefinition behavior
authorRuss Cox <rsc@golang.org>
Wed, 19 Oct 2016 03:22:38 +0000 (23:22 -0400)
committerRuss Cox <rsc@golang.org>
Wed, 19 Oct 2016 12:57:09 +0000 (12:57 +0000)
commit2f7f679c79009137bd34fcc33a6d3a6762f45e75
tree711f35e4b75d1942815bb6030701b964a1272edc
parentae14472af9e9508eab948303b14290ca98d09646
html/template, text/template: clarify template redefinition behavior

Make two important points clearer:

 - Giving a template definition containing
   nothing but spaces has no effect.
 - Giving a template definition containing
   non-spaces can only be done once per template.

Fixes #16912.
Fixes #16913.
Fixes #17360.

Change-Id: Ie3971b83ab148b7c8bb800fe4a21579566378e3e
Reviewed-on: https://go-review.googlesource.com/31459
Run-TryBot: Russ Cox <rsc@golang.org>
Reviewed-by: Rob Pike <r@golang.org>
Reviewed-by: Andrew Gerrand <adg@golang.org>
src/html/template/template.go
src/text/template/template.go