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

Improve diagnostic location in nls #1856

Merged
merged 2 commits into from
Mar 15, 2024
Merged

Improve diagnostic location in nls #1856

merged 2 commits into from
Mar 15, 2024

Conversation

jneem
Copy link
Member

@jneem jneem commented Mar 14, 2024

This adds a better heuristic for the "main" location of a diagnostic: we take the first label with the "primary" style, instead of just the first label.

In practice, this means that contract errors point first to the location of the value that violates the contract (whereas previously they were pointing to the contract itself).

@jneem jneem requested review from yannham and vkleen March 14, 2024 22:09
@github-actions github-actions bot temporarily deployed to pull request March 14, 2024 22:11 Inactive
@jneem jneem added this pull request to the merge queue Mar 15, 2024
Merged via the queue into master with commit e5bdef6 Mar 15, 2024
5 checks passed
@jneem jneem deleted the diagnostic-location branch March 15, 2024 18:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants