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

feat: Allow viewing the full compiler diagnostic in a readonly textview #13633

Merged
merged 2 commits into from
Nov 18, 2022

Conversation

Veykril
Copy link
Member

@Veykril Veykril commented Nov 18, 2022

Code_y1qrash9gg

Also adds a VSCode only config that replaces the split diagnostic message with the first relevant part of the diagnostic output

Code_7k4qsMkx5e

This only affects diagnostics generated by primary spans and has no effect on other clients than VSCode.

Fixes #13574

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 18, 2022
@bjorn3
Copy link
Member

bjorn3 commented Nov 18, 2022

If you hover over an error there is a "View Problem" button, right? Can you put the full diagnostic in the peek it shows when pressing this button?

image

@Veykril
Copy link
Member Author

Veykril commented Nov 18, 2022

That is just VSCode rendering the diagnostic messages you see on hover in the red box, not much we can do there

@bjorn3
Copy link
Member

bjorn3 commented Nov 18, 2022

Really, they don't allow putting a full diagnostic in there? Why do they even have that button then?

@Veykril
Copy link
Member Author

Veykril commented Nov 18, 2022

VSCode basically allows you to do nothing with diagnostics :)

@bjorn3
Copy link
Member

bjorn3 commented Nov 18, 2022

😭

@Veykril
Copy link
Member Author

Veykril commented Nov 18, 2022

@bors r+

@bors
Copy link
Collaborator

bors commented Nov 18, 2022

📌 Commit 8452844 has been approved by Veykril

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented Nov 18, 2022

⌛ Testing commit 8452844 with merge 791cb87...

@bors
Copy link
Collaborator

bors commented Nov 18, 2022

☀️ Test successful - checks-actions
Approved by: Veykril
Pushing 791cb87 to master...

@ChayimFriedman2
Copy link
Contributor

We need to make it so when people copy the diagnostic it'll copy the full diagnostic (don't think we can do that, unfortunately).

@Veykril
Copy link
Member Author

Veykril commented Nov 21, 2022

What exactly do you mean with that?

@ChayimFriedman2
Copy link
Contributor

People many times ask for help with the truncated rust-analyzer diagnostic. It would be nice if copying it would result in the full diagnostic being copied.

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.

Include rustc diagnostic ASCII art in popup
5 participants