Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use strip_{prefix|suffix} instead of {starts|ends}_with+indexing #138566

Merged
merged 1 commit into from
Mar 17, 2025

Conversation

yotamofek
Copy link
Contributor

Randomly scratching an itch 😁

@rustbot
Copy link
Collaborator

rustbot commented Mar 16, 2025

r? @nnethercote

rustbot has assigned @nnethercote.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Mar 16, 2025
@rustbot
Copy link
Collaborator

rustbot commented Mar 16, 2025

HIR ty lowering was modified

cc @fmease

Some changes occurred in compiler/rustc_codegen_ssa

cc @WaffleLapkin

@rust-log-analyzer

This comment has been minimized.

@nnethercote
Copy link
Contributor

Nice to remove these magic numbers, thanks. Just a couple of minor nits to address.

@nnethercote nnethercote added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 17, 2025
@yotamofek
Copy link
Contributor Author

@rustbot review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Mar 17, 2025
@nnethercote
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Mar 17, 2025

📌 Commit a3e4dff has been approved by nnethercote

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 17, 2025
@bors
Copy link
Contributor

bors commented Mar 17, 2025

⌛ Testing commit a3e4dff with merge 9bad8ac...

@bors
Copy link
Contributor

bors commented Mar 17, 2025

☀️ Test successful - checks-actions
Approved by: nnethercote
Pushing 9bad8ac to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Mar 17, 2025
@bors bors merged commit 9bad8ac into rust-lang:master Mar 17, 2025
7 checks passed
@rustbot rustbot added this to the 1.87.0 milestone Mar 17, 2025
Copy link

This is an experimental post-merge analysis report. You can ignore it.

Post-merge report

Comparing 10bcdad (base) -> 9bad8ac (this PR)

Test differences

No test diffs found

@yotamofek yotamofek deleted the pr/strip-prefix branch March 17, 2025 10:46
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (9bad8ac): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results (secondary -0.1%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
2.5% [2.5%, 2.5%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-1.4% [-1.4%, -1.3%] 2
All ❌✅ (primary) - - 0

Cycles

Results (primary -0.7%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-0.7% [-0.7%, -0.7%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -0.7% [-0.7%, -0.7%] 1

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 775.561s -> 776.387s (0.11%)
Artifact size: 365.14 MiB -> 365.11 MiB (-0.01%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants