Skip to content

Commit 31f5b4e

Browse files
committed
Update ScalaPresentationCompiler.scala
1 parent 8d3c8ca commit 31f5b4e

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

presentation-compiler/src/main/dotty/tools/pc/ScalaPresentationCompiler.scala

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -79,15 +79,14 @@ case class ScalaPresentationCompiler(
7979
params: OffsetParams,
8080
codeActionId: String,
8181
codeActionPayload: Optional[T]
82-
): CompletableFuture[ju.List[TextEdit]] = {
83-
(codeActionId, codeActionPayload.asScala) match {
82+
): CompletableFuture[ju.List[TextEdit]] =
83+
(codeActionId, codeActionPayload.asScala) match
8484
case (
8585
CodeActionId.ConvertToNamedArguments,
8686
Some(argIndices: ju.List[_])
8787
) =>
88-
val payload = argIndices.asScala.collect { case i: Integer =>
89-
i.toInt
90-
}.toSet
88+
val payload =
89+
argIndices.asScala.collect { case i: Integer => i.toInt }.toSet
9190
convertToNamedArguments(params, payload)
9291
case (CodeActionId.ImplementAbstractMembers, _) =>
9392
implementAbstractMembers(params)
@@ -108,8 +107,6 @@ case class ScalaPresentationCompiler(
108107
CompletableFuture.failedFuture(
109108
new IllegalArgumentException(s"Unsupported action id $id")
110109
)
111-
}
112-
}
113110

114111
override def withCompletionItemPriority(
115112
priority: CompletionItemPriority

0 commit comments

Comments
 (0)