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

Simplify format_args builtin macro implementation. #100277

Merged
merged 2 commits into from
Aug 15, 2022

Conversation

m-ou-se
Copy link
Member

@m-ou-se m-ou-se commented Aug 8, 2022

Instead of a FxHashMap<Symbol, (usize, Span)> for the named arguments, this now includes the name and span in the elements of the Vec directly. The FxHashMap still exists to look up the index, but no longer contains the span. Looking up the name or span of an argument is now trivial and does not need the map anymore.

Instead of a FxHashMap<Symbol, (usize, Span)> for the named arguments,
this now includes the name and span in the elements of the
Vec<FormatArg> directly. The FxHashMap still exists to look up the
index, but no longer contains the span. Looking up the name or span of
an argument is now trivial and does not need the map anymore.
@m-ou-se m-ou-se added the C-cleanup Category: PRs that clean code up or issues documenting cleanup. label Aug 8, 2022
@rust-highfive
Copy link
Collaborator

r? @jackh726

(rust-highfive has picked a reviewer for you, use r? to override)

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Aug 8, 2022
@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 8, 2022
@m-ou-se
Copy link
Member Author

m-ou-se commented Aug 8, 2022

r? @compiler-errors I think you were the last person to review things in this file. :)

@compiler-errors
Copy link
Member

Thanks!

@bors r+

@bors
Copy link
Contributor

bors commented Aug 14, 2022

📌 Commit a639fdb has been approved by compiler-errors

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 Aug 14, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 15, 2022
…iaskrgr

Rollup of 6 pull requests

Successful merges:

 - rust-lang#100211 (Refuse to codegen an upstream static.)
 - rust-lang#100277 (Simplify format_args builtin macro implementation.)
 - rust-lang#100483 (Point to generic or arg if it's the self type of unsatisfied projection predicate)
 - rust-lang#100506 (change `InlineAsmCtxt` to not talk about `FnCtxt`)
 - rust-lang#100534 (Make code slightly more uniform)
 - rust-lang#100566 (Use `create_snapshot_for_diagnostic` instead of `clone` for `Parser`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 965ed81 into rust-lang:master Aug 15, 2022
@rustbot rustbot added this to the 1.65.0 milestone Aug 15, 2022
@m-ou-se m-ou-se deleted the format-args-1 branch August 15, 2022 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-cleanup Category: PRs that clean code up or issues documenting cleanup. 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.

6 participants