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

Support for GHC 9.10 #64

Open
wants to merge 25 commits into
base: main
Choose a base branch
from
Open

Conversation

wz1000
Copy link
Contributor

@wz1000 wz1000 commented May 15, 2024

Needs a ghc-exactprint release, currently builds against https://github.com/alanz/ghc-exactprint/tree/ghc-9.10

@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label May 15, 2024
@wz1000
Copy link
Contributor Author

wz1000 commented May 22, 2024

@pepeiborra this should be ready to merge.

@watashi
Copy link
Contributor

watashi commented May 22, 2024

Can we also add ghc 9.10.1 to CI? or ghc 9.10 support can be broken again without notice in the future.

https://github.com/facebookincubator/retrie/blob/main/.github/workflows/test.yml#L12,L16

@pepeiborra
Copy link
Contributor

Ping @wz1000

@wz1000
Copy link
Contributor Author

wz1000 commented May 24, 2024

I am looking at the test failures.

wz1000 and others added 19 commits May 31, 2024 13:16
- Remove earlier comments from previous upgrade
- Add CPP to silence a bunch of warnings
By adjusting the paren addition code, 9.10 exactprint uses spans for
delta calcs, we can keep them
Drops to 17/86
whitespace, commenting debug bits
When we finalise the templates, do makeDeltaAst for all variants.

This fixes Types2 and Parens tests, but breaks

Readme1
Types3
Types4
We need the patterns to be located, to not replace the original when
matching.

Down to 6/86
Brings it to 5/86 remaining failures
This is used to filter out potential matches in the file the query
originates in.

But often we have had to re-arrange it with deltas at the point of
matching, so can no longer easily extract it from the pattern to be
matched.

Instead we store it explicitly when making a Query
Still 5/86 failures, but fewer failing instances in PatternSyn2
This sorts out surrounding spacing.

Down to 4/86
Recursion /is/ needed, because we are moving things around at this
level, the child nodes may need re-arranging as a result

Still 3/86, but they all relate to comments. I think.
Which has made most exactprint transform functions pure, rather than
in TransFormT.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants