]> Cypherpunks.ru repositories - gostls13.git/commit
html/template: revert "avoid race when escaping updates template"
authorIan Lance Taylor <iant@golang.org>
Fri, 22 Jan 2021 22:54:23 +0000 (14:54 -0800)
committerIan Lance Taylor <iant@golang.org>
Mon, 25 Jan 2021 20:41:05 +0000 (20:41 +0000)
commit3d85c69a0bf67adec57b76511ccc5e5b0ba9cdf4
tree523c7ee20a7f03c0985e1e442f663d0999261e81
parent54514c6b2896c6a634a7b8017ade909985172e4d
html/template: revert "avoid race when escaping updates template"

This reverts CLs 274450 and 279492, except for the new tests.
The new race test is changed to skip, as it now fails.
We can try again for 1.17.

Original CL descriptions:

    html/template: attach functions to namespace

    The text/template functions are stored in a data structure shared by
    all related templates, so do the same with the original, unwrapped,
    functions on the html/template side.

    html/template: avoid race when escaping updates template

For #39807
Fixes #43855

Change-Id: I2ce91321ada06ea496a982aefe170eb5af9ba847
Reviewed-on: https://go-review.googlesource.com/c/go/+/285957
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Emmanuel Odeke <emmanuel@orijtech.com>
src/html/template/exec_test.go
src/html/template/template.go