stylish-haskell
stylish-haskell copied to clipboard
Utrecht style commas?
How much work is it to use Utrecht-style commas in the import lists?
Not that hard, I'll try to fix it this week.
Could you give a specific example of the preferred style? I'm not sure what I should do with the closing )
, should it always be on a separate line?
import Foo ( foo
, bar
, baz
, quux
)
It's always on a separate line in Utrecht style IIRC.
This would be nice to have! Though i'm not sure if I prefer an import on each line or like this:
import Foo ( foo, bar
, baz, quux
)
I saw that there was a branch for this, what's the status of it @jaspervdj? No pressure :)
Is this fixed somehow? I whould be very interested in this.
No it's not fixed. I have a fork that does utrecht formatting for language pragmas, would be nice to be able to merge this (related: #64) but it's quite some work I'd imagine.
Hi @jaspervdj I just checked this and it looks like it's not been done yet. In fact, I can simply use a mix of trailing and leading commas and stylish-haskell doesn't change anything. Is this the expected behavior?
A little surprised this isn't implemented, yet. But, I also don't have time to dig into it right now.
Thanks for a great tool, @jaspervdj .
This is indeed still not implemented; I don't use this style myself and don't really have time to implement it right now, but I would welcome a PR adding it.
If anyone here is willing to contribute example formatting output by (failing) tests, I would be happy to pick it up (implement, making test green).