code: func (t *tree) errorf(format string, args ...interface{}) {
  	// get current token (taking account of backups)
  	var tok = t.token[0]
  	if t.peekCount > 0 {
  		tok = t.token[t.peekCount-1]
  	}
  	t.root = nil
  	format = fmt.Sprintf("template %s:%d:%d: %s", t.name,
  		t.lex.lineNumber(tok.pos), t.lex.columnNumber(tok.pos), format)
  	panic(
  		errortypes.NewErrFilePosf(
  			t.name,
  			t.lex.lineNumber(tok.pos),
  			t.lex.columnNumber(tok.pos),
  			format,
  			args...,
  		),
  	)
  }
docs: // errorf formats the error and terminates processing.