Skip to content

Commit 31e5444

Browse files
committed
style: add nolint for gocritic badCond
1 parent 48d64c7 commit 31e5444

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

meta/findall.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,7 @@ func (e *Engine) findAllIndicesLoop(haystack []byte, n int, results [][2]int) []
146146
// Skip empty matches that start exactly where the previous non-empty match ended.
147147
// This matches Go's stdlib behavior:
148148
// - "a*" on "ab" returns [[0 1] [2 2]], not [[0 1] [1 1] [2 2]]
149+
//nolint:gocritic // badCond: intentional - checking empty match (start==end) at lastMatchEnd
149150
if start == end && start == lastMatchEnd {
150151
pos++
151152
if pos > len(haystack) {

0 commit comments

Comments
 (0)