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

Inline format args (better perf) #91

Merged
merged 1 commit into from
Nov 13, 2023
Merged

Inline format args (better perf) #91

merged 1 commit into from
Nov 13, 2023

Conversation

nyurik
Copy link
Contributor

@nyurik nyurik commented Nov 6, 2023

This is a subset of the original #84

Make code a bit easier to read, and also, per rust issue 112156, there is a 6% perf hit when using refs with format, so this PR also fixes that.

See rust-lang/rust#112156

Make code a bit easier to read, and also, per rust issue 112156, there is a 6% perf hit when using refs with format, so this PR also fixes that.
@nyurik nyurik mentioned this pull request Nov 6, 2023
1 task
@nyurik
Copy link
Contributor Author

nyurik commented Nov 13, 2023

@m4b can this be merged too? It is another fairly simple cleanup

@m4b
Copy link
Owner

m4b commented Nov 13, 2023

i don't think it matters for tests (or does it) but which rust version did fmt strings get the {foo} syntax? we are set to 1.63 at the moment

@nyurik
Copy link
Contributor Author

nyurik commented Nov 13, 2023

@m4b format inline was in 1.58 - https://releases.rs/docs/1.58.0/

Copy link
Owner

@m4b m4b left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great thanks for looking it up, i does matter actually since error.rs (which would be compiled by downstream crates) now uses this feature

@m4b m4b merged commit 30f49c7 into m4b:master Nov 13, 2023
6 checks passed
@nyurik nyurik deleted the inline-fmt-args branch November 13, 2023 06:25
m4b pushed a commit that referenced this pull request Dec 31, 2023
Make code a bit easier to read, and also, per rust issue 112156, there is a 6% perf hit when using refs with format, so this PR also fixes that.
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.

2 participants