Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Top level type declarations don't line-break properly. #64

Open
Philonous opened this issue Jul 8, 2021 · 0 comments
Open

Top level type declarations don't line-break properly. #64

Philonous opened this issue Jul 8, 2021 · 0 comments

Comments

@Philonous
Copy link

When setting "formatting"."layout"."type" to "vertical" or "try-oneline" (with a long declaration) and "formatting"."indent"."typesig": "indent-by 2"

I would expect the following formatting:

function
  :: Bool
  -> Int
  -> Double
  -> String
  -> [Int]
  -> Either (Maybe String) Bool
  -> IO Bool
function = undefined

However, floskell instead produces

function :: Bool
  -> Int
  -> Double
  -> String
  -> [Int]
  -> Either (Maybe String) Bool
  -> IO Bool
function = undefined

That is, the first Parameter is on the wrong line

setting "formatting"."indent"."typesig": "align" actually does produce the desired behaviour as long as the function name is 16 characters or longer.

This seems like a bug to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant