Skip to content

Fix eager token mapping panics - #15248

Merged
bors merged 2 commits into
rust-lang:masterfrom
Veykril:eager
Jul 13, 2023
Merged

bors merged 2 commits into
rust-lang:masterfrom
Veykril:eager

Conversation

@Veykril

@Veykril Veykril commented Jul 10, 2023

Copy link
Copy Markdown
Member

No description provided.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jul 10, 2023
@bors

bors commented Jul 10, 2023

Copy link
Copy Markdown
Contributor

☔ The latest upstream changes (presumably #15251) made this pull request unmergeable. Please resolve the merge conflicts.

@Veykril
Veykril force-pushed the eager branch 2 times, most recently from dc2aecd to e0a2cb6 Compare July 13, 2023 07:20
@Veykril
Veykril marked this pull request as ready for review July 13, 2023 07:36
@Veykril

Veykril commented Jul 13, 2023 •

Copy link
Copy Markdown
Member Author

Alright, I managed to make token mapping work again. There is still a problem here though, any macro calls in eager macro calls won't resolve properly, as they do not actually exist in any graspable expansion. That is in format_args!("{}", vec![]) the vec! call won't resolve in the IDE layer as it does not exist in the format_args output (as it was already expanded). We'll need to rewrite the eager expansion a bit by storing the expanded input in the db somewhere and then handle that as any other macro expansion. I don't have the time to do that right now though.

I also didn't check the perf impact of this PR but I hope its not too bad. (it will most likely increase mem usage a bit)
@bors r+

@bors

bors commented Jul 13, 2023

Copy link
Copy Markdown
Contributor

📌 Commit 6a7b905 has been approved by Veykril

It is now in the queue for this repository.

@bors

bors commented Jul 13, 2023

Copy link
Copy Markdown
Contributor

⌛ Testing commit 6a7b905 with merge 132ba2c...

@bors

bors commented Jul 13, 2023

Copy link
Copy Markdown
Contributor

☀️ Test successful - checks-actions
Approved by: Veykril
Pushing 132ba2c to master...

@bors
bors merged commit 132ba2c into rust-lang:master Jul 13, 2023
@Veykril
Veykril deleted the eager branch July 30, 2023 10:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants