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

Split README / Fix Scalaz #94

Merged
merged 3 commits into from
Nov 20, 2017
Merged

Split README / Fix Scalaz #94

merged 3 commits into from
Nov 20, 2017

Conversation

andyscott
Copy link
Member

@andyscott andyscott commented Nov 18, 2017

There are a few remaining fixes in the tests to get the build green, but:

  • Split the README into separate docs for Cats / Scalaz
  • Add guards for alerting users of the slight issue with Scalaz's variances on NaturalTransformation.
  • "Fix" Scalaz support

Fixing Scalaz support

There was one big issue related to type inferencing for the parameters on CopK.NaturalTransformation.of/summon. After a bit of debugging while at SBTB I've sorted out what seems to be the best solution.

The short story is that the variances on Scalaz's NaturalTransformation cause the typer to simply assume Nothing (or use an existential type) instead of computing a type tag. A potential solution was posted on SO several years ago, but this doesn't work for this use case.

For the time being, Scalaz users will need to specify the type parameters when calling . If variances are removed from Scalaz, then this requirement should seamlessly disappear.

Thanks to @propensive for macro debugging assistance and @jdegoes for Scalaz roadmap discussion.

@andyscott andyscott merged commit d0d0498 into master Nov 20, 2017
@andyscott andyscott deleted the fix-scalaz branch November 20, 2017 00:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant