From 7ed5bcaef9dbab6781affcaf55a9398d20eb9fd6 Mon Sep 17 00:00:00 2001 From: Jon Pretty Date: Sat, 14 Dec 2024 07:48:56 +0100 Subject: [PATCH] Whitespace changes --- src/core/adversaria.Adversaria.scala | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/src/core/adversaria.Adversaria.scala b/src/core/adversaria.Adversaria.scala index bd2dbf5..d062ddf 100644 --- a/src/core/adversaria.Adversaria.scala +++ b/src/core/adversaria.Adversaria.scala @@ -36,11 +36,12 @@ object Adversaria: fields.flatMap: field => field.annotations.map(_.asExpr).collect: case '{$annotation: AnnotationType} => annotation - .map: annotation => - '{CaseField(Text(${Expr(field.name)}), (target: TargetType) => - ${'target.asTerm.select(field).asExpr}, $annotation)} - .reverse - .head + + . map: annotation => + '{CaseField(Text(${Expr(field.name)}), (target: TargetType) => + ${'target.asTerm.select(field).asExpr}, $annotation)} + . reverse + . head def fields[TargetType <: Product: Type, AnnotationType <: StaticAnnotation: Type](using Quotes) : Expr[List[CaseField[TargetType, AnnotationType]]] = @@ -54,10 +55,12 @@ object Adversaria: val name = Expr(field.name) field.annotations.map(_.asExpr).collect: case '{$annotation: AnnotationType} => annotation - .map: annotation => - '{CaseField(Text($name), (target: TargetType) => ${'target.asTerm.select(field).asExpr}, - $annotation)} - .reverse + + . map: annotation => + '{CaseField(Text($name), (target: TargetType) => ${'target.asTerm.select(field).asExpr}, + $annotation)} + + . reverse Expr.ofList(elements)