diff options
Diffstat (limited to 'src/pkg/template/parse/parse.go')
| -rw-r--r-- | src/pkg/template/parse/parse.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/pkg/template/parse/parse.go b/src/pkg/template/parse/parse.go index 9a411a3f3..691807466 100644 --- a/src/pkg/template/parse/parse.go +++ b/src/pkg/template/parse/parse.go @@ -173,7 +173,7 @@ func (t *Tree) itemList(toEOF bool) (list *ListNode, next Node) { for t.peek().typ != itemEOF { n := t.textOrAction() switch n.Type() { - case NodeEnd, NodeElse: + case nodeEnd, nodeElse: return list, n } list.append(n) @@ -278,10 +278,10 @@ func (t *Tree) parseControl(context string) (lineNum int, pipe *PipeNode, list, var next Node list, next = t.itemList(false) switch next.Type() { - case NodeEnd: //done - case NodeElse: + case nodeEnd: //done + case nodeElse: elseList, next = t.itemList(false) - if next.Type() != NodeEnd { + if next.Type() != nodeEnd { t.errorf("expected end; found %s", next) } elseList = elseList |
