Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Scala Steward: Reformat with scalafmt 3.11.0
35c718b0be5e1993a829a86e5270e822ae97f274
2 changes: 1 addition & 1 deletion .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version = 3.7.17
version = 3.11.0
runner.dialect = scala3
runner.dialectOverride.allowSignificantIndentation = false

Expand Down
12 changes: 6 additions & 6 deletions core/src/main/scala/respectfully/API.scala
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ object API {
'{
Endpoint[Any, Any](
${ Expr(meth.name) },
${ inputCodec }.asInstanceOf[Codec[Any]],
${ outputCodec }.asInstanceOf[Codec[Any]],
$inputCodec.asInstanceOf[Codec[Any]],
$outputCodec.asInstanceOf[Codec[Any]],
)
}
}
Expand Down Expand Up @@ -172,7 +172,7 @@ object API {

val fromFunction: Expr[AsFunction => Alg] = '{ asf => ${ proxy[Alg]('asf).asExprOf[Alg] } }

'{ API.instance[Alg](${ Expr.ofList(endpoints) }, ${ asFunction }, ${ fromFunction }) }
'{ API.instance[Alg](${ Expr.ofList(endpoints) }, $asFunction, $fromFunction) }
}

private inline def combineCodecs(
Expand Down Expand Up @@ -257,10 +257,10 @@ object API {
val body: List[DefDef] = cls.declaredMethods.map { sym =>
def impl(argss: List[List[Tree]]) = {
argss match {
case Nil :: Nil => '{ ${ asf }.apply(${ Expr(sym.name) }, Nil) }
case _ =>
case Nil :: Nil => '{ $asf.apply(${ Expr(sym.name) }, Nil) }
case _ =>
'{
${ asf }.apply(
$asf.apply(
endpointName = ${ Expr(sym.name) },
in =
${
Expand Down
Loading