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.
This supersedes both #151 and #155.
This mostly deals with the usual churn between
ghc
versions (and relaxes other package bounds), but there was one non-trivial change. Thelarge-anon
plugin was generating code that looked something like this:In
ghc >= 9.6
this no longer works, becauseShow Bool :: Constraint
, and the type arguments ofunsafeCoerce
have kindType
, andType
andConstraint
are no longer the same thing in core starting in 9.6. We therefore now go through an indirection usingDict
, so that the above code becomesThis nearly resolves the problem, except that for some reason I also had to mark
evidenceAllFields
inData.Record.Anon.Plugin.Internal.Runtime
asNOINLINE
, otherwise we still get-dcore-lint
errors, but only with-O1
. This almost feels like a ghc bug, but I don't have time to investigate this further at this point.@TristanCacqueray and @gbrsales, I have combined your work and my own changes into this one commit. I've listed both of you in the git commit as
Co-authored-by
, and also listed you where appropriate in theChangeLog.md
entries. I hope that's okay.