Ticket #212 (new bug report)
Parse errors with family keyword
| Reported by: | NeilMitchell2 | Owned by: | nibro |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Component: | parser | Version: | |
| Keywords: | Cc: | ndmitchell@… |
Description
Parsing the following fragments with import Language.Haskell.Exts; parseFile "Test.hs", I get the results:
{-# LANGUAGE TypeFamilies #-}
f family = undefined
-- ParseFailed (SrcLoc {srcFilename = "Test.hs", srcLine = 2, srcColumn = 3}) "TemplateHaskell is not enabled"
{-# LANGUAGE TypeFamilies, TemplateHaskell #-}
f family = undefined
-- ParseFailed (SrcLoc {srcFilename = "Test.hs", srcLine = 2, srcColumn = 3}) "Parse error: family"
Both these fragments are accepted by GHC. The TemplateHaskell? suggestion in the first case is not very good. This issue is based on a bug report against HLint, http://code.google.com/p/ndmitchell/issues/detail?id=402 , and all results were under 1.10.1.
Change History
Note: See
TracTickets for help on using
tickets.
