Skip to content

Add Declaration Location to Refinement Errors - #285

Open
rcosta358 wants to merge 1 commit into
mainfrom
declaration-locations
Open

Add Declaration Location to Refinement Errors#285
rcosta358 wants to merge 1 commit into
mainfrom
declaration-locations

Conversation

@rcosta358

@rcosta358 rcosta358 commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator

Description

This PR adds refinement declaration locations to refinement and state refinement errors.
This is also used by the VS Code extension for typestate errors to get the file that contains the state refinements and generate the state machine diagram for each one.

Example

Command-Line Interface

image

VS Code

image

Related Issue

None.

Type of change

  • Bug fix
  • New feature
  • Documentation update
  • Code refactoring

Checklist

  • Added/updated tests under liquidjava-example/src/main/java/testSuite/ (Correct* / Error*)
  • mvn test passes locally
  • Updated docs/README if behavior or API changed

@rcosta358 rcosta358 self-assigned this Aug 9, 2026
@rcosta358 rcosta358 added enhancement New feature or request error messages Related to error messages labels Aug 9, 2026
@rcosta358

rcosta358 commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator Author

Initially I experimented with showing the snippet for the refinement location, but that way error messages are a bit larger and more confusing, especially with counterexamples and other hints.
I think the simple clickable path for the refinement location is enough, but we can easily change that in the future.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request error messages Related to error messages

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant