Skip to content

Commit

Permalink
Add test for #20342
Browse files Browse the repository at this point in the history
  • Loading branch information
noti0na1 committed May 14, 2024
1 parent d29a4a8 commit ee091ca
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tests/pos/i20342.scala
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
class Repo[EC, E](using defaults: RepoDefaults[EC, E])
trait RepoDefaults[EC, E]
object RepoDefaults:
inline given genImmutableRepo[E: DbCodec]: RepoDefaults[E, E] = ???
inline given genRepo[EC: DbCodec, E: DbCodec]: RepoDefaults[EC, E] = ???

trait DbCodec[E]

case class PersonCreator(name: String)
case class Person(id: Long)
given DbCodec[Person] = ???
given DbCodec[PersonCreator] = ???

@main def Test =
val personRepo = Repo[PersonCreator, Person]

0 comments on commit ee091ca

Please sign in to comment.