From 95163f331d2d063bcb2ca80e31e3b81dfdb956a7 Mon Sep 17 00:00:00 2001 From: "Michael K." <130953568+kmichaelk@users.noreply.github.com> Date: Fri, 15 Nov 2024 23:30:59 +0300 Subject: [PATCH] Revert "Fix integer conversion (#767)" This reverts commit 395523c94d70231cc985b240f135e8e2203d9f95. --- internal/lsp/span/parse.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/internal/lsp/span/parse.go b/internal/lsp/span/parse.go index 204f704b..4defbdc2 100644 --- a/internal/lsp/span/parse.go +++ b/internal/lsp/span/parse.go @@ -8,7 +8,6 @@ import ( "strconv" "strings" "unicode/utf8" - "math" ) // Parse returns the location represented by the input. @@ -87,10 +86,8 @@ func rstripSuffix(input string) suffix { if last >= 0 && last < len(remains)-1 { number, err := strconv.ParseInt(remains[last+1:], 10, 64) if err == nil { - if number >= math.MinInt && number <= math.MaxInt { - num = int(number) - remains = remains[:last+1] - } + num = int(number) + remains = remains[:last+1] } } // now see if we have a trailing separator