Closed kquick closed 5 years ago
A couple of additional notes:
There was a similar removal of a generic default case for the TH-generated equality: https://github.com/emilaxelsson/syntactic/commit/5735b4cd4895ad231ca32e4f1874b197278f461d
The original set of tests do not pass in my setup. It was necessary to comment-out the prop_codeMotion_vars
, prop_codeMotion_eval
, and prop_bug1
tests to avoid non-termination of the tests (due to the castExprCM
issue?). There are still test failures after removing these tests, but the testing now terminates.
The TravisCI link from the main github page is apparently testing the 1.x branch, so I was unable to use that to confirm the test failures I am seeing. Also rather oddly, examining the raw logs of Travis shows that Travis aborted the job due to excessive and repetitious output, but flagged the build as passing.
With the addition of the explicit prj tests, but with the default Project case still in place (and with the 3 codeMotion tests above removed), the result is 22 failures out of 33 tests. Removing the default Project case improved things considerably beyond the added explicit prj tests: only 7 failures out of 33 tests.
Thanks for fixing this!
I'll fix the Travis build and try to make sure that recent GHCs are supported.
@kquick Did you forget to add the file SyntaxTests.hs
?
@emilaxelsson looks like I did, sorry about that! It's been added now.
Good, thanks! I'm still working on getting a green build on Travis.
Just an update: I'm making slow progress. The failures turned out to be due to incorrectly specified overlap, combined with a GHC bug (see comment 3, which shows what happens in Syntactic).
Now the tests pass on GHC 8.4, but I get an infinite loop on 8.2 (and Travis shows a failing test on 8.2). Once I've resolved testing on GHC 8.2, I'll upload a new version.
Interesting bug; hopefully the 8.8 fix will introduce more noise from the compiler about these.
Thanks for the update!
After holidays and a lot of testing on different versions (including my packages that depend on Syntactic) I finally got things to work, except on GHC 8.2, unfortunately. See the comment to the instance below.
instance {-# OVERLAPPABLE #-} BindingDomain sym
where
prVar _ = Nothing
prLam _ = Nothing
renameBind _ a = a
-- This instance seems to overlap all others on GHC 8.2.2. This leads to
-- failures in the test suite. Removing the instance and declaring one
-- instance per type solves the problem. Earlier and later GHC versions don't
-- have this problem, so I assume it's a bug in 8.2.
I've explicitly disabled GHC 8.2 in the Cabal file.
Thanks for your patch and for getting things going!
The addition of the catch-all for
Project
(https://github.com/emilaxelsson/syntactic/commit/9b1ddf2e) causesprj
to always returnNothing
because the catch-all is seen as a substitution instance for the:+:
composition instances.Added explicit unit tests to validate
prj
functionality.