
#15646: ghci takes super long time to find the type of large fractional number -------------------------------------+------------------------------------- Reporter: Johannkokos | Owner: | JulianLeviston Type: bug | Status: new Priority: normal | Milestone: 8.6.1 Component: GHCi | Version: 8.4.3 Resolution: | Keywords: newcomer Operating System: Unknown/Multiple | Architecture: Type of failure: Compile-time | Unknown/Multiple performance bug | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by JulianLeviston): I got it compiling and typechecking, then set about writing a test. Discussed with you (osa1) and a couple others in IRC about writing tests. Looked more into how the testing framework works, read up on writing tests. Pretty sure I can figure that out now (it's really not going to be hard, once I read all the test guides). So that's fine, but I had an issue compiling after doing a `git pull` (for some reason I had to recompile stage 1 of the compiler again), so I recompiled and thought I'd try out my changes. So I typechecked a large scientific notational literal, and it got `*** Exception: No match in record selector thfl_value` I realised immediately that was because I'd just made the types match in the desugarer and renamer by using the new TH part of the FractionalLit type because the desugarer talks bout pattern group matching on HsFractional and seemed to expect a Rational. So, the `PatGroup` data type, has a constructor `PgN :: Rational -> PatGroup` which I'm now going to refactor to be `PgN :: Integer -> Integer -> PatGroup`. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/15646#comment:39 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler