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

parse error on constrained record gadt #183

Open
qdbp opened this issue Oct 1, 2017 · 1 comment
Open

parse error on constrained record gadt #183

qdbp opened this issue Oct 1, 2017 · 1 comment

Comments

@qdbp
Copy link

qdbp commented Oct 1, 2017

stylish-haskell fails on the following:

{-# LANGUAGE GADTs #-}

data Foo a where
    Foo :: (Eq a) => {
            fooBar :: [a],
            fooBaz :: Int
        } -> Foo a

main = putStrLn "foo"

with this error:
Language.Haskell.Stylish.Parse.parseModule: could not parse fail.hs: ParseFailed (SrcLoc "<unknown>.hs" 4 22) "Parse error: {"

It works if I remove the (Eq a) constraint. Ghc is able to compile this file properly, so I assume it's a stylish-haskell error.

@JoeMShanahan
Copy link

Any update on this? @jaspervdj

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

2 participants