I've been trying to solve the issue #6188, but It seems there are no tests for formatting source files containing "dbg" (The only tests I've found for "roc format" are in "crates/compiler/test_syntax/tests/test_fmt.rs"). Is that really the case, and if so, should I write some?
There are snapshot tests in crates/compiler/test_syntax/tests/snapshots/
A passing dbg example is crates/compiler/test_syntax/tests/snapshots/pass/dbg.expr.formatted
Which comes from formatting: crates/compiler/test_syntax/tests/snapshots/pass/dbg.expr.roc
It looks like that may be the only example.
And it is wrong based on the new standard
I see... I'll try to correct these, and maybe write some more
Should
dbg (1,
2)
format to:
dbg
(
1,
2,
)
?
I could see this being nicer:
dbg (
1,
2,
)
Thanks. I'm working on my first commit, so this seems quite challenging, but I'll try to implement that.
I believe that I've done it. I made a pull request (#6241), though I'm afraid, I might have messed something up with theverification... 0.0 What should I do now?
I kick off the test suite. Hopefully the tests pass and someone with more familiarity around formatting can give you a review.
Thanks!
Realized the PR was super simple so just reviewed it myself.
ptaszor has marked this topic as resolved.
Last updated: Jul 06 2025 at 12:14 UTC