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

Use simpler abbreviations when reporting error types #105322

Open
sophiajt opened this issue Dec 5, 2022 · 0 comments
Open

Use simpler abbreviations when reporting error types #105322

sophiajt opened this issue Dec 5, 2022 · 0 comments
Labels
A-diagnostics Area: Messages for errors, warnings, and lints T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@sophiajt
Copy link
Contributor

sophiajt commented Dec 5, 2022

Given the following code:

image

Ideally the output should look like:

Rather than printing the full types to the user, perhaps we want to have a kind of type abbreviation for readability.

The closure type [closure@f52.rs:13:18 13:21] is not one the user can type in, nor likely one they'll even track down in the source code. We could potentially just say closure (and specify it is unique in some way)

For the std::slice::Iter, I wonder if this is some we might abbreviate for readability. Granted Iter by itself is ambiguous, but perhaps there's a simpler way we could write this to allow more space for other information to the user.

@sophiajt sophiajt added A-diagnostics Area: Messages for errors, warnings, and lints T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Dec 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-diagnostics Area: Messages for errors, warnings, and lints T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

1 participant