[GHC] #9745: qual_pkg panic with template haskell

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Keywords: | Operating System: Architecture: Unknown/Multiple | Unknown/Multiple Difficulty: Unknown | Type of failure: Blocked By: | None/Unknown Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- I'm updating some things that use Template Haskell to derive lenses to work with GHC HEAD, but I'm getting the following error. My `cabal- install` a fresh build from the master branch of the `cabal` repository. {{{ src/Lib.hs:11:1:ghc: panic! (the 'impossible' happened) (GHC version 7.9.20141029 for x86_64-unknown-linux): qual_pkg lens-4.5.0.0.1 }}} lenstest.cabal {{{ name: lenstest version: 0.1.0.0 license-file: LICENSE author: Luite Stegeman maintainer: stegeman@gmail.com build-type: Simple cabal-version: >=1.10 library build-depends: base >= 4.8 && < 4.9, lens >= 4.5 exposed-modules: Lib default-language: Haskell2010 hs-source-dirs: src }}} src/Lib.hs: {{{#!hs {-# LANGUAGE TemplateHaskell #-} module Lib where import Control.Lens data XY = X Int | Y String makeLenses ''XY makePrisms ''XY }}} The `lens` and `free` packages need to be patched to work with the latest GHC, because of a conflict with `Data.Bifunctor`. I've attached updated version that use `PackageImports` to get the module from `bifunctors` as a workaround. Use {{{ cabal install --allow-newer }}} to install, since some dependencies have too restrictive upper bounds. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: | Blocked By: None/Unknown | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by luite): Sorry, the updated lens package couldn't be attached because it's bigger than the 256kB file size limit. Get it here: http://hdiff.luite.com/tmp/lens-4.5.0.0.1.tar.gz -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: ezyang Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: | Blocked By: None/Unknown | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Changes (by ezyang): * owner: => ezyang -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: ezyang Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: | Blocked By: None/Unknown | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by ezyang): `semigroups` doesn't seem to compile for me, what version are you using? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: ezyang Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: | Blocked By: None/Unknown | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by luite): It's `lens` that generates a name with a package version, not key: https://github.com/ekmett/lens/blob/b28d8658a3abf166d81eeffc8297a934116a97ef... -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: ezyang Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: invalid | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: | Blocked By: None/Unknown | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Changes (by ezyang): * status: new => closed * resolution: => invalid Comment: Ahhh, very nice catch! I grepped for key like things but I must have missed this. So, let's close as not our bug... -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Changes (by ezyang): * owner: ezyang => * status: closed => new * resolution: invalid => -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9745: qual_pkg panic with template haskell -------------------------------------+------------------------------------- Reporter: luite | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: duplicate | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: None/Unknown | Unknown/Multiple Blocked By: | Test Case: Related Tickets: #10279 | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Changes (by ezyang): * status: new => closed * resolution: => duplicate * related: => #10279 Comment: We decided that there are some fixes we should do here, see #10279 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9745#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC