Skip to content

Commit

Permalink
parse: remove unneeded state transitions
Browse files Browse the repository at this point in the history
this was found after adding more test cases
and finding that those lines were not covered
  • Loading branch information
neiser committed Feb 11, 2023
1 parent e735695 commit 5f08da9
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions parse/lex.go
Original file line number Diff line number Diff line change
Expand Up @@ -246,10 +246,6 @@ func lexSubstitution(l *lexer) stateFn {
l.subsDepth--
l.emit(itemRightDelim)
return lexText
case r == eof || isEndOfLine(r):
return l.errorf("closing brace expected")
case isAlphaNumeric(r) && strings.HasPrefix(l.input[l.lastPos:], "${"):
fallthrough
case r == '$':
return lexVariable
default:
Expand Down

0 comments on commit 5f08da9

Please sign in to comment.