Skip to content

Commit

Permalink
Fix printing of InlineMatch nodes.
Browse files Browse the repository at this point in the history
  • Loading branch information
sjrd committed Nov 29, 2023
1 parent b8008da commit 8cd5141
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions tasty-query/shared/src/main/scala/tastyquery/Printers.scala
Original file line number Diff line number Diff line change
Expand Up @@ -393,8 +393,13 @@ private[tastyquery] object Printers:
print(")")

case InlineMatch(selector, cases) =>
print("inline ")
print(InlineMatch(selector, cases)(tree.pos))
print("(inline ")
selector match
case Some(sel) => print(sel)
case None => print("_")
print(" match")
printBlock(cases)(print(_))
print(")")

case SeqLiteral(elems, elemtpt) =>
print("[")
Expand Down

0 comments on commit 8cd5141

Please sign in to comment.