Skip to content

refactor: replace Split in loops with more efficient SplitSeq and replace HasPrefix+TrimPrefix with CutPrefix#13810

Open
caltechustc wants to merge 1 commit into
docker:mainfrom
caltechustc:main
Open

refactor: replace Split in loops with more efficient SplitSeq and replace HasPrefix+TrimPrefix with CutPrefix#13810
caltechustc wants to merge 1 commit into
docker:mainfrom
caltechustc:main

Conversation

@caltechustc
Copy link
Copy Markdown

@caltechustc caltechustc commented May 23, 2026

What I did

Optimize code using a more modern writing style which can make the code more efficient and cleaner.

And also use strings.CutPrefix for clearer and more idiomatic prefix handling.

More info: golang/go#61901

Related issue

(not mandatory) A picture of a cute animal, if possible in relation to what you did

image

…lace HasPrefix+TrimPrefix with CutPrefix

Signed-off-by: caltechustc <caltechustc@outlook.com>
@caltechustc caltechustc requested a review from a team as a code owner May 23, 2026 12:11
@caltechustc caltechustc requested review from glours and ndeloof May 23, 2026 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant