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

Indirect covariant comparison involving a higher-kinded type argument fails #469

Open
neko-kai opened this issue Jul 1, 2024 · 2 comments
Labels
💎 Bounty bug Something isn't working

Comments

@neko-kai
Copy link
Member

neko-kai commented Jul 1, 2024

From zio/zio#8215

trait Container[T] {
  def getT(): T
}

trait Service[+O[_] <: Container[_]] {
  def giveHello: String
}

final case class AContainer[T](t: T) extends Container[T] {
  override def getT() = t
} 

final case class MyConcreteService() extends Service[AContainer] {
  def giveHello = "Concrete hello!"
}

object Example extends App {

  implicitly[MyConcreteService <:< Service[Container]] // true

  val left = izumi.reflect.Tag[MyConcreteService]
  val right = izumi.reflect.Tag[Service[Container]]

  println(left <:< right) // false
}
@jdegoes
Copy link
Member

jdegoes commented Nov 8, 2024

/bounty $500

Copy link

algora-pbc bot commented Nov 8, 2024

💎 $500 bounty • ZIO

Steps to solve:

  1. Start working: Comment /attempt #469 with your implementation plan
  2. Submit work: Create a pull request including /claim #469 in the PR body to claim the bounty
  3. Receive payment: 100% of the bounty is received 2-5 days post-reward. Make sure you are eligible for payouts

Thank you for contributing to zio/izumi-reflect!

Add a bountyShare on socials

@pshirshov pshirshov added the bug Something isn't working label Nov 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💎 Bounty bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants