Replies: 1 comment 3 replies
-
Thanks for the question! I think |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
The default behavior of Scalameta's formatting changes chains like this:
into this:
because Chisel's
when
/elsewhen
/otherwise
are technically a function chain and not "real" syntax likeif
/else if
/etc. I'd far prefer to keep them indented the same, instead of having the subsequent blocks indented.I tried
newlines.selectChains = fold
, but I have two issues with it:Is there a way to configure .scalafmt.conf to just not indent function chains? I don't care if it leads to "normal" function chains being non indented, like this:
I tried using
indentOperator.excludeRegex
andindentOperator.exclude
but nothing I did seemed to have any impact.Scala/Metals/Scalafmt versions:
Beta Was this translation helpful? Give feedback.
All reactions