Skip to content

Commit

Permalink
Go back to shorter form of literal function
Browse files Browse the repository at this point in the history
  • Loading branch information
riccardocorbella committed Nov 27, 2020
1 parent 5e68812 commit be11790
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions core/jvm/src/main/scala/zio/sql/expr.scala
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,7 @@ trait ExprModule extends NewtypesModule with FeaturesModule with OpsModule {

def typeTagOf[A](expr: Expr[_, _, A]): TypeTag[A] = expr.asInstanceOf[InvariantExpr[_, _, A]].typeTag

implicit def literal[A](a: A)(implicit typeTag: TypeTag[A]): Expr[Features.Literal, Any, A] = typeTag match {
case _ => Expr.Literal(a)
}
implicit def literal[A: TypeTag](a: A): Expr[Features.Literal, Any, A] = Expr.Literal(a)

def exprName[F, A, B](expr: Expr[F, A, B]): Option[String] =
expr match {
Expand Down

0 comments on commit be11790

Please sign in to comment.