Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
  • Loading branch information
hawkingrei committed Sep 4, 2024
1 parent 1d0cc96 commit c6fa020
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/parser/lexer.go
Original file line number Diff line number Diff line change
Expand Up @@ -954,13 +954,13 @@ func (s *Scanner) scanDigits() string {

// scanVersionDigits scans for `min` to `max` digits (range inclusive) used in
// `/*!12345 ... */` comments.
func (s *Scanner) scanVersionDigits(min, max int) {
func (s *Scanner) scanVersionDigits(mini, maxv int) {
pos := s.r.pos()
for i := 0; i < max; i++ {
for i := 0; i < maxv; i++ {
ch := s.r.peek()
if isDigit(ch) {
s.r.inc()
} else if i < min {
} else if i < mini {
s.r.updatePos(pos)
return
} else {
Expand Down

0 comments on commit c6fa020

Please sign in to comment.