promql: Eliminate dead code (#6215)

peek() already ensures to not return a ItemComment so checking for this
is redundant.

Signed-off-by: Tobias Guggenmos <tguggenm@redhat.com>
This commit is contained in:
Tobias Guggenmos 2019-10-25 10:18:20 +02:00 committed by Julius Volz
parent 95d3d3f7ed
commit fe80cf4734
1 changed files with 0 additions and 3 deletions

View File

@ -106,9 +106,6 @@ func (p *parser) parseExpr() (expr Expr, err error) {
defer p.recover(&err)
for p.peek().typ != ItemEOF {
if p.peek().typ == ItemComment {
continue
}
if expr != nil {
p.errorf("could not parse remaining input %.15q...", p.lex.input[p.lex.lastPos:])
}