-
Notifications
You must be signed in to change notification settings - Fork 16
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
fix(ast): inconsistent Display
implementations for variables
#442
Merged
ozgurakgun
merged 1 commit into
conjure-cp:main
from
niklasdewally:pr/fix-variable-display
Nov 12, 2024
Merged
fix(ast): inconsistent Display
implementations for variables
#442
ozgurakgun
merged 1 commit into
conjure-cp:main
from
niklasdewally:pr/fix-variable-display
Nov 12, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Didn't realise that this was used in the tester... |
ozgurakgun
approved these changes
Nov 12, 2024
Approved, I guess as per the new recommended workflow either you autosquash or I squash merge? |
Change display implementations of Name, Factor, and Expression so that variables are always printed the same way. Previously, each of these implemented the printing of references themselves in different ways. For example, Name display used `MachineName(x)`, and Expressions `__x`. Now, variable display is only defined in `Name`. Instead of directly displaying references for `FactorE(Factor::Reference(...))` in Expression's display implementation, this instead calls display for `Factor`. In turn, `Factor` calls display for `Name` and `Literal` instead of implementing this itself.
niklasdewally
force-pushed
the
pr/fix-variable-display
branch
from
November 12, 2024 18:09
54e1766
to
665fdf2
Compare
@ozgurakgun ready to merge. |
Code and Documentation Coverage ReportDocumentation CoverageClick to view documentation coverage for this PR
Click to view documentation coverage for main
Code Coverage SummaryThis PR: Detailed Report
Main: Detailed Report
Coverage Main & PR Coverage ChangeLines coverage changed by 0.10% and covered lines changed by 0
Functions coverage changed by 0.00% and covered lines changed by 0
Branches... coverage: No comparison data available |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Change display implementations of Name, Factor, and Expression so that variables are always printed the same way.
Previously, each of these implemented the printing of references themselves in different ways. For example, Name display used
MachineName(x)
, and Expressions__x
.Now, variable display is only defined in
Name
. Instead of directly displaying references forFactorE(Factor::Reference(...))
in Expression's display implementation, this instead calls display forFactor
. In turn,Factor
calls display forName
andLiteral
instead of implementing this itself.