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

#794: Derivation tools for external newtypes #873

Open
wants to merge 1 commit into
base: series/1.x
Choose a base branch
from

Conversation

soujiro32167
Copy link

No description provided.

@soujiro32167 soujiro32167 requested a review from a team as a code owner February 16, 2022 22:23
Copy link
Member

@sideeffffect sideeffffect left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 👍

@sideeffffect
Copy link
Member

Please run sbt fix to fix the problems (formatting in this case, I think).

@soujiro32167 soujiro32167 force-pushed the 794-external-typeclass-derivation branch from c8b7f2a to 565ceab Compare February 17, 2022 14:34
@soujiro32167 soujiro32167 force-pushed the 794-external-typeclass-derivation branch from 565ceab to 4d35eed Compare February 17, 2022 15:07
@soujiro32167
Copy link
Author

Erm, I have no idea how to deal with this Scala 3 error:

[error] -- Error: /home/runner/work/zio-prelude/zio-prelude/core/shared/src/main/scala/zio/prelude/newtypes/derivation.scala:6:94 
[error] 6 |  def derive[A, STA <: Newtype[A], F[_]](implicit ev: STA <:< Newtype[A], typeClass: F[A]): F[STA#Type] =
[error]   |                                                                                              ^^^
[error]   |                                           STA is not a legal path
[error]   |                                           since it is not a concrete type

Please halp 😱

@sideeffffect
Copy link
Member

It may be the cases that this is actually not possible in Scala 3: https://docs.scala-lang.org/scala3/reference/dropped-features/type-projection.html

@soujiro32167
Copy link
Author

I'll move it to Scala2 for now v_v

@sideeffffect
Copy link
Member

Hi @soujiro32167 would you like to continue working on this?

@soujiro32167
Copy link
Author

Yeah, totally forgot about this 😅

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.

2 participants