From 3b2ac047277b7aa5c770cd5a0f19fe822ab350cf Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Mon, 13 Jan 2025 02:33:39 +0000 Subject: [PATCH 1/3] Update scalafmt-core to 3.8.4 --- .scalafmt.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.scalafmt.conf b/.scalafmt.conf index 858d639f..15b73a3c 100644 --- a/.scalafmt.conf +++ b/.scalafmt.conf @@ -1,4 +1,4 @@ -version = "3.8.1" +version = "3.8.4" maxColumn = 120 align.preset = most continuationIndent.defnSite = 2 From fe6afbbbb23fdc643736503bf55e810b60f3ecf4 Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Mon, 13 Jan 2025 02:34:07 +0000 Subject: [PATCH 2/3] Reformat with scalafmt 3.8.4 Executed command: scalafmt --non-interactive --- .../src/main/scala/zio/sql/select/Read.scala | 12 ++++-- .../main/scala/zio/sql/typetag/TypeTag.scala | 4 +- .../sql/utils/TrailingUnitNormalizer.scala | 40 +++++++++---------- .../scala-2/zio/sql/macros/insertlike.scala | 2 +- .../zio/sql/mysql/MysqlRenderModule.scala | 4 +- 5 files changed, 34 insertions(+), 28 deletions(-) diff --git a/core/jvm/src/main/scala/zio/sql/select/Read.scala b/core/jvm/src/main/scala/zio/sql/select/Read.scala index bc485927..9c2abdc1 100644 --- a/core/jvm/src/main/scala/zio/sql/select/Read.scala +++ b/core/jvm/src/main/scala/zio/sql/select/Read.scala @@ -255,7 +255,9 @@ object Read { expr3: Expr[F3, Source, Any], expr4: Expr[F4, Source, Any], expr5: Expr[F5, Source, Any] - )(implicit verify: GroupByLike[F, F1 with F2 with F3 with F4 with F5]): Subselect.WithGroupByF[ + )(implicit + verify: GroupByLike[F, F1 with F2 with F3 with F4 with F5] + ): Subselect.WithGroupByF[ F, Repr, Source, @@ -284,7 +286,9 @@ object Read { expr4: Expr[F4, Source, Any], expr5: Expr[F5, Source, Any], expr6: Expr[F6, Source, Any] - )(implicit verify: GroupByLike[F, F1 with F2 with F3 with F4 with F5 with F6]): Subselect.WithGroupByF[ + )(implicit + verify: GroupByLike[F, F1 with F2 with F3 with F4 with F5 with F6] + ): Subselect.WithGroupByF[ F, Repr, Source, @@ -315,7 +319,9 @@ object Read { expr5: Expr[F5, Source, Any], expr6: Expr[F6, Source, Any], expr7: Expr[F7, Source, Any] - )(implicit verify: GroupByLike[F, F1 with F2 with F3 with F4 with F5 with F6 with F7]): Subselect.WithGroupByF[ + )(implicit + verify: GroupByLike[F, F1 with F2 with F3 with F4 with F5 with F6 with F7] + ): Subselect.WithGroupByF[ F, Repr, Source, diff --git a/core/jvm/src/main/scala/zio/sql/typetag/TypeTag.scala b/core/jvm/src/main/scala/zio/sql/typetag/TypeTag.scala index 7115cb9f..dc07b9f2 100644 --- a/core/jvm/src/main/scala/zio/sql/typetag/TypeTag.scala +++ b/core/jvm/src/main/scala/zio/sql/typetag/TypeTag.scala @@ -105,7 +105,7 @@ object TypeTag { } // TODO get TypeTag of A available out of Schema[A] and derive typetag from Schema.Transform - case _: Schema.Transform[_, _, _] => None - case _ => None + case _: Schema.Transform[_, _, _] => None + case _ => None } } diff --git a/core/jvm/src/main/scala/zio/sql/utils/TrailingUnitNormalizer.scala b/core/jvm/src/main/scala/zio/sql/utils/TrailingUnitNormalizer.scala index 2de8d78a..d5e3f7fe 100644 --- a/core/jvm/src/main/scala/zio/sql/utils/TrailingUnitNormalizer.scala +++ b/core/jvm/src/main/scala/zio/sql/utils/TrailingUnitNormalizer.scala @@ -14,49 +14,49 @@ object TrailingUnitNormalizer { implicit def arity1[In, A]: TrailingUnitNormalizer.WithOut[(A, Unit), A] = new TrailingUnitNormalizer[(A, Unit)] { override type Out = A - override def apply(in: (A, Unit)): A = + override def apply(in: (A, Unit)): A = in._1 } implicit def arity2[In, A, B]: TrailingUnitNormalizer.WithOut[(A, (B, Unit)), (A, B)] = new TrailingUnitNormalizer[(A, (B, Unit))] { override type Out = (A, B) - override def apply(in: (A, (B, Unit))): Out = + override def apply(in: (A, (B, Unit))): Out = (in._1, in._2._1) } implicit def arity3[In, A, B, C]: TrailingUnitNormalizer.WithOut[(A, (B, (C, Unit))), (A, B, C)] = new TrailingUnitNormalizer[(A, (B, (C, Unit)))] { override type Out = (A, B, C) - override def apply(in: (A, (B, (C, Unit))) ): Out = + override def apply(in: (A, (B, (C, Unit))) ): Out = (in._1, in._2._1, in._2._2._1) } implicit def arity4[In, A, B, C, D]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, Unit)))), (A, B, C, D)] = new TrailingUnitNormalizer[(A, (B, (C, (D, Unit))))] { override type Out = (A, B, C, D) - override def apply(in: (A, (B, (C, (D, Unit))))): Out = + override def apply(in: (A, (B, (C, (D, Unit))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1) } implicit def arity5[In, A, B, C, D, E]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, Unit))))), (A, B, C, D, E)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, Unit)))))] { override type Out = (A, B, C, D, E) - override def apply(in: (A, (B, (C, (D, (E, Unit)))))): Out = + override def apply(in: (A, (B, (C, (D, (E, Unit)))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1) } implicit def arity6[In, A, B, C, D, E, F]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, Unit)))))), (A, B, C, D, E, F)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, Unit))))))] { override type Out = (A, B, C, D, E, F) - override def apply(in: (A, (B, (C, (D, (E, (F, Unit))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, Unit))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1) } implicit def arity7[In, A, B, C, D, E, F, G]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, Unit))))))), (A, B, C, D, E, F, G)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, Unit)))))))] { override type Out = (A, B, C, D, E, F, G) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, Unit)))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, Unit)))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1) } @@ -70,49 +70,49 @@ object TrailingUnitNormalizer { implicit def arity9[In, A, B, C, D, E, F, G, H, I]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, Unit))))))))), (A, B, C, D, E, F, G, H, I)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, Unit)))))))))] { override type Out = (A, B, C, D, E, F, G, H, I) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, Unit)))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, Unit)))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1) } implicit def arity10[In, A, B, C, D, E, F, G, H, I, J]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, Unit)))))))))), (A, B, C, D, E, F, G, H, I, J)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, Unit))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, Unit))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, Unit))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1) } implicit def arity11[In, A, B, C, D, E, F, G, H, I, J, K]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, Unit))))))))))), (A, B, C, D, E, F, G, H, I, J, K)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, Unit)))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, Unit)))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, Unit)))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity12[In, A, B, C, D, E, F, G, H, I, J, K, L]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, Unit)))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, Unit))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, Unit))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, Unit))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity13[In, A, B, C, D, E, F, G, H, I, J, K, L, M]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, Unit))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, Unit)))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, Unit)))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, Unit)))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity14[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, Unit)))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, Unit))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, Unit))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, Unit))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity15[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, Unit))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, Unit)))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, Unit)))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, Unit)))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } @@ -126,41 +126,41 @@ object TrailingUnitNormalizer { implicit def arity17[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, Unit))))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, Unit)))))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, Unit)))))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, Unit)))))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity18[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, Unit)))))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, Unit))))))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, Unit))))))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, Unit))))))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity19[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, Unit))))))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, Unit)))))))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, Unit))))))))))))))))))) ): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, Unit))))))))))))))))))) ): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity20[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, Unit)))))))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, Unit))))))))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, Unit))))))))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, Unit))))))))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity21[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, Unit))))))))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, Unit)))))))))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, Unit)))))))))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, Unit)))))))))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } implicit def arity22[In, A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V]: TrailingUnitNormalizer.WithOut[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, (V, Unit)))))))))))))))))))))), (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V)] = new TrailingUnitNormalizer[(A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, (V, Unit))))))))))))))))))))))] { override type Out = (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V) - override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, (V, Unit))))))))))))))))))))))): Out = + override def apply(in: (A, (B, (C, (D, (E, (F, (G, (H, (I, (J, (K, (L, (M, (N, (O, (P, (Q, (R, (S, (T, (U, (V, Unit))))))))))))))))))))))): Out = (in._1, in._2._1, in._2._2._1, in._2._2._2._1, in._2._2._2._2._1, in._2._2._2._2._2._1, in._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1, in._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._2._1) } // format: on diff --git a/macros/src/main/scala-2/zio/sql/macros/insertlike.scala b/macros/src/main/scala-2/zio/sql/macros/insertlike.scala index b8ead35c..3f850ed7 100644 --- a/macros/src/main/scala-2/zio/sql/macros/insertlike.scala +++ b/macros/src/main/scala-2/zio/sql/macros/insertlike.scala @@ -91,7 +91,7 @@ object InsertLike { if (toInsert.typeSymbol.asClass.isCaseClass) { toInsert.dealias match { // for case classes - case TypeRef(_, _, types) if types == Nil => + case TypeRef(_, _, types) if types == Nil => toInsert.decls.sorted.collect { case p: TermSymbol if p.isCaseAccessor && !p.isMethod => p.typeSignature match { diff --git a/mysql/src/main/scala/zio/sql/mysql/MysqlRenderModule.scala b/mysql/src/main/scala/zio/sql/mysql/MysqlRenderModule.scala index 353a682d..7be02cd5 100644 --- a/mysql/src/main/scala/zio/sql/mysql/MysqlRenderModule.scala +++ b/mysql/src/main/scala/zio/sql/mysql/MysqlRenderModule.scala @@ -412,7 +412,7 @@ trait MysqlRenderModule extends MysqlSqlModule { self => render( lit.value.asInstanceOf[Chunk[Byte]].map("""\%02X""" format _).mkString("x'", "", "'") ) // todo fix `cast` infers correctly but map doesn't work for some reason - case tt @ TChar => + case tt @ TChar => render("'", tt.cast(lit.value), "'") // todo is this the same as a string? fix escaping case tt @ TInstant => render("TIMESTAMP '", tt.cast(lit.value), "'") @@ -448,7 +448,7 @@ trait MysqlRenderModule extends MysqlSqlModule { self => render(lit.value) case TString => render("'", lit.value, "'") // todo fix escaping - case _ => + case _ => render(lit.value) // todo fix add TypeTag.Nullable[_] => } } From ae1c55a963e38d762f74415efe43f2bdf091e214 Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Mon, 13 Jan 2025 02:34:08 +0000 Subject: [PATCH 3/3] Add 'Reformat with scalafmt 3.8.4' to .git-blame-ignore-revs --- .git-blame-ignore-revs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs index ad60c8cd..d429a4b0 100644 --- a/.git-blame-ignore-revs +++ b/.git-blame-ignore-revs @@ -1,2 +1,5 @@ # Scala Steward: Reformat with scalafmt 3.7.10 9bcedec20a4fc7adedce8aea4921c05b0c7acfa4 + +# Scala Steward: Reformat with scalafmt 3.8.4 +fe6afbbbb23fdc643736503bf55e810b60f3ecf4