dualfroz fd69f1aadd fix(strutil): clamp Substr stop index to avoid out-of-range panic
Substr panicked with a slice-bounds error when a negative length trimmed
more runes than remained after pos, because stopIdx (strLn + length) could
fall before pos. Clamp stopIdx to pos so an over-long negative trim returns
an empty string, matching the existing pos >= strLn guard.
2026-09-06 00:44:31 +02:00
S
Description
My contributions to gookit/goutil: 4 commits, 1 merged PRs
49 KiB
0 Stars 1 Watchers 0 Forks
Languages
Go 100%