()
| 840 | } |
| 841 | |
| 842 | func (t *templateEndCtrlToken) Name() string { |
| 843 | switch t.Type { |
| 844 | case templateEndIf: |
| 845 | return "endif" |
| 846 | case templateElse: |
| 847 | return "else" |
| 848 | case templateEndFor: |
| 849 | return "endfor" |
| 850 | default: |
| 851 | // should never happen |
| 852 | panic("invalid templateEndCtrlType") |
| 853 | } |
| 854 | } |
| 855 | |
| 856 | type templateEndToken struct { |
| 857 | SrcRange hcl.Range |