Descriptiontext/template: allow {{else if ... }} to simplify if chains
The method is simple: the parser just parses
{{if A}}a{{else if B}}b{{end}}
to the same tree that would be produced by
{{if A}}a{{else}}{{if B}}b{{end}}{{end}}
Thus no changes are required in text/template itself
or in html/template, only in text/template/parse.
Fixes issue 6085
Patch Set 1 #Patch Set 2 : diff -r 4a2a2c758ca5 https://code.google.com/p/go/ #
MessagesTotal messages: 3
|