Brittany unaligns Aeson .= operator #85

Open
opened 2017-12-18 21:04:22 +01:00 by matthew-piziak · 1 comment
matthew-piziak commented 2017-12-18 21:04:22 +01:00 (Migrated from github.com)

Hi @lspitzner, I hope you don't mind me dropping by with more examples. I imagine you have a more general issue for this, so as always feel free to close it as a duplicate.

If I take a nicely aligned list like this...

payload = encode $ object
  [ "a_long_binding"       .= ("foo" :: Text)
  , "another_long_binding" .= ("bar" :: Text)
  , "a_binding"            .= ("baz" :: Text)
  , "bind"                 .= (15 :: Int)
  , "biiiiind"             .= (15 :: Int)
  ]

...brittany will reformat it to look like this:

payload = encode $ object
  [ "a_long_binding" .= ("foo" :: Text)
  , "another_long_binding" .= ("bar" :: Text)
  , "a_binding" .= ("baz" :: Text)
  , "bind" .= (15 :: Int)
  , "biiiiind" .= (15 :: Int)
  ]

What are your thoughts on this?

Thanks!

Hi @lspitzner, I hope you don't mind me dropping by with more examples. I imagine you have a more general issue for this, so as always feel free to close it as a duplicate. If I take a nicely aligned list like this... ``` payload = encode $ object [ "a_long_binding" .= ("foo" :: Text) , "another_long_binding" .= ("bar" :: Text) , "a_binding" .= ("baz" :: Text) , "bind" .= (15 :: Int) , "biiiiind" .= (15 :: Int) ] ``` ...`brittany` will reformat it to look like this: ``` payload = encode $ object [ "a_long_binding" .= ("foo" :: Text) , "another_long_binding" .= ("bar" :: Text) , "a_binding" .= ("baz" :: Text) , "bind" .= (15 :: Int) , "biiiiind" .= (15 :: Int) ] ``` What are your thoughts on this? Thanks!
lspitzner commented 2017-12-21 22:27:46 +01:00 (Migrated from github.com)

Looks like some alignment stuff is missing for infix applications. Probably relatively easy to fix, I'll take a look soon (TM).

Looks like some alignment stuff is missing for infix applications. Probably relatively easy to fix, I'll take a look soon (TM).
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: hexagoxel/brittany#85
There is no content yet.