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

Fix format macro expansions spans to be macro-generated #64793

Merged
merged 1 commit into from Sep 29, 2019

Conversation

@rinon
Copy link
Contributor

commented Sep 26, 2019

New Exprs generated as part of the format macro expansion should get the macro
expansion span with an expansion context, rather than the span of the format string
which does not.

New Exprs generated as part of the format macro expansion should get the macro
expansion span which has an expansion context, not the span of the format string
which does not.
@rust-highfive

This comment has been minimized.

Copy link
Collaborator

commented Sep 26, 2019

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @alexcrichton (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@rinon

This comment has been minimized.

Copy link
Contributor Author

commented Sep 26, 2019

This changed the output of one test due to the new span of the macro expansion, but that looks correct to me.

@Centril

This comment has been minimized.

Copy link
Member

commented Sep 26, 2019

@matthewjasper

This comment has been minimized.

Copy link
Contributor

commented Sep 26, 2019

@bors r+

I should probably listen to my own comments more:

// FIXME use a better heuristic than Spans

@bors

This comment has been minimized.

Copy link
Contributor

commented Sep 26, 2019

📌 Commit 0ec4513 has been approved by matthewjasper

rinon added a commit to immunant/c2rust that referenced this pull request Sep 26, 2019
@rinon rinon referenced this pull request Sep 26, 2019
Centril added a commit to Centril/rust that referenced this pull request Sep 27, 2019
Fix format macro expansions spans to be macro-generated

New Exprs generated as part of the format macro expansion should get the macro
expansion span with an expansion context, rather than the span of the format string
which does not.
bors added a commit that referenced this pull request Sep 27, 2019
Rollup of 10 pull requests

Successful merges:

 - #63937 ( Fix ICE in rustdoc when merging generic and where bounds of an Fn with an output)
 - #64419 (Deduplicate some code between miri and const prop)
 - #64546 (Bugfix/rfc 2451 rerebalance tests)
 - #64589 (Differentiate AArch64 bare-metal targets between hf and non-hf.)
 - #64745 (Include message on tests that should panic but do not)
 - #64793 (Fix format macro expansions spans to be macro-generated)
 - #64799 (Fix double panic when printing query stack during an ICE)
 - #64802 (Account for tail expressions when pointing at return type)
 - #64815 (Fix div_duration() marked as stable by mistake)
 - #64818 (update rtpSpawn's parameters type(It's prototype has been updated in libc))

Failed merges:

r? @ghost
Centril added a commit to Centril/rust that referenced this pull request Sep 27, 2019
Fix format macro expansions spans to be macro-generated

New Exprs generated as part of the format macro expansion should get the macro
expansion span with an expansion context, rather than the span of the format string
which does not.
Centril added a commit to Centril/rust that referenced this pull request Sep 28, 2019
Fix format macro expansions spans to be macro-generated

New Exprs generated as part of the format macro expansion should get the macro
expansion span with an expansion context, rather than the span of the format string
which does not.
bors added a commit that referenced this pull request Sep 28, 2019
Rollup of 6 pull requests

Successful merges:

 - #64455 (Add Long error explanation for E0531)
 - #64546 (Bugfix/rfc 2451 rerebalance tests)
 - #64589 (Differentiate AArch64 bare-metal targets between hf and non-hf.)
 - #64763 (Add E0734 and its long explanation)
 - #64793 (Fix format macro expansions spans to be macro-generated)
 - #64799 (Fix double panic when printing query stack during an ICE)

Failed merges:

r? @ghost
Centril added a commit to Centril/rust that referenced this pull request Sep 28, 2019
Fix format macro expansions spans to be macro-generated

New Exprs generated as part of the format macro expansion should get the macro
expansion span with an expansion context, rather than the span of the format string
which does not.
bors added a commit that referenced this pull request Sep 28, 2019
Rollup of 10 pull requests

Successful merges:

 - #64131 (data_structures: Add deterministic FxHashMap and FxHashSet wrappers)
 - #64387 (Fix redundant semicolon lint interaction with proc macro attributes)
 - #64678 (added more context for duplicate lang item errors (fixes #60561))
 - #64763 (Add E0734 and its long explanation)
 - #64793 (Fix format macro expansions spans to be macro-generated)
 - #64837 (Improve wording in documentation of MaybeUninit)
 - #64852 (Print ParamTy span when accessing a field (#52082))
 - #64875 (Upgrade async/await to "used" keywords.)
 - #64876 (Fix typo in intrinsics op safety)
 - #64880 (Slice docs: fix typo)

Failed merges:

r? @ghost
@bors bors merged commit 0ec4513 into rust-lang:master Sep 29, 2019
4 checks passed
4 checks passed
pr Build #20190926.4 succeeded
Details
pr (Linux mingw-check) Linux mingw-check succeeded
Details
pr (Linux x86_64-gnu-llvm-6.0) Linux x86_64-gnu-llvm-6.0 succeeded
Details
pr (LinuxTools) LinuxTools succeeded
Details
@rinon rinon deleted the immunant:format_spans branch Oct 1, 2019
rinon added a commit to immunant/c2rust that referenced this pull request Oct 1, 2019
rinon added a commit to immunant/c2rust that referenced this pull request Oct 2, 2019
rinon added a commit to immunant/c2rust that referenced this pull request Oct 7, 2019
rinon added a commit to immunant/c2rust that referenced this pull request Oct 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
You can’t perform that action at this time.