Skip to content

Commit

Permalink
explicit type annotations for implicits
Browse files Browse the repository at this point in the history
  • Loading branch information
googley42 committed Jul 22, 2023
1 parent 7b50178 commit 89500a6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions dynamodb/src/main/scala/zio/dynamodb/proofs/IsPrimaryKey.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import scala.annotation.implicitNotFound
sealed trait IsPrimaryKey[A]

object IsPrimaryKey {
implicit val intIsPrimaryKey = new IsPrimaryKey[Int] {}
implicit val intIsPrimaryKey: IsPrimaryKey[Int] = new IsPrimaryKey[Int] {}
// TODO: Avi - support other numeric types

implicit val stringIsPrimaryKey = new IsPrimaryKey[String] {}
implicit val stringIsPrimaryKey: IsPrimaryKey[String] = new IsPrimaryKey[String] {}

// binary data
implicit val binaryIsPrimaryKey = new IsPrimaryKey[Iterable[Byte]] {}
implicit val binaryIsPrimaryKey2 = new IsPrimaryKey[List[Byte]] {}
implicit val binaryIsPrimaryKey3 = new IsPrimaryKey[Vector[Byte]] {}
implicit val binaryIsPrimaryKey: IsPrimaryKey[Iterable[Byte]] = new IsPrimaryKey[Iterable[Byte]] {}
implicit val binaryIsPrimaryKey2: IsPrimaryKey[List[Byte]] = new IsPrimaryKey[List[Byte]] {}
implicit val binaryIsPrimaryKey3: IsPrimaryKey[Vector[Byte]] = new IsPrimaryKey[Vector[Byte]] {}
// TODO: Avi - other collection types
}

0 comments on commit 89500a6

Please sign in to comment.