[GHC] #11050: [bug] ModOrigin: hidden module redefined

#11050: [bug] ModOrigin: hidden module redefined -------------------------------------+------------------------------------- Reporter: codeonwort | Owner: Type: bug | Status: new Priority: normal | Milestone: 7.10.3 Component: Compiler | Version: 7.10.2 Keywords: | Operating System: Linux Architecture: x86_64 | Type of failure: Compile-time (amd64) | crash Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- {{{#!hs 1 import Haste 2 import Haste.DOM 3 import Haste.Graphics.Canvas 4 import Control.Monad 5 6 mkCanvas width height = do 7 canvas <- newElem "canvas" 8 setProp canvas "width" $ show width 9 setProp canvas "height" $ show height 10 let conf = [("display", "block"), ("border", "1px solid black"), ("margin", "0px auto 0 aut o"), ("backgroundColor", "black")] 11 mapM_ (\(style, value) -> setStyle canvas style value) conf 12 return canvas 13 14 picture = fill $ rect (0, 0) (600, 600) 15 16 main = do 17 canv <- mkCanvas 600 600 18 addChild canv documentBody 19 Just canv <- getCanvas canv 20 render canv picture }}} ------------------------------------------------------------------------ hello.hs:18:3: Warning:hastec: hastec: panic! (the 'impossible' happened) (GHC version 7.10.2 for x86_64-unknown-linux): ModOrigin: hidden module redefined Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug ------------------------------------------------------------------------ I was following the tutorial on http://ifeanyi.co/posts/client-side- haskell/ and got this bug. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11050 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11050: [bug] ModOrigin: hidden module redefined -------------------------------------+------------------------------------- Reporter: codeonwort | Owner: Type: bug | Status: new Priority: normal | Milestone: 8.0.1 Component: Compiler | Version: 7.10.2 Resolution: | Keywords: Operating System: Linux | Architecture: x86_64 Type of failure: Compile-time | (amd64) crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * milestone: 7.10.3 => 8.0.1 Comment: To reproduce on Ubuntu with ghc-7.10.2: * Install the `haste-compiler` Debian package from http://haste- lang.org/downloads/ * Create `T11050.hs`: {{{ import Haste.DOM main = do addChild undefined undefined return () }}} * Run {{{ $ ghc -no-user-package-db -package-db=/usr/lib/haste-compiler/x86_64 -linux-haste-0.5.2-ghc-7.10.2/package.conf.d T11050.hs -fforce-recomp }}} Somehow, `haste` managed to create a package (`haste-lib`) that lists all hidden modules twice: {{{ $ ghc-pkg --package-db=/usr/lib/haste-compiler/x86_64-linux- haste-0.5.2-ghc-7.10.2/package.conf.d describe haste-lib ... hidden-modules: Haste.App.Client Haste.App.Monad Haste.App.Protocol Haste.Audio.Events Haste.Binary.Get Haste.Binary.Put Haste.Binary.Types Haste.Compiler.Flags Haste.Concurrent.Monad Haste.Concurrent.Ajax Haste.DOM.Core Haste.Events.BasicEvents Haste.Events.Core Haste.Events.KeyEvents Haste.Events.MouseEvents Haste.Events.TouchEvents Haste.Hash Haste.Random Haste.Timer Haste.App.Client Haste.App.Monad Haste.App.Protocol Haste.Audio.Events Haste.Binary.Get Haste.Binary.Put Haste.Binary.Types Haste.Compiler.Flags Haste.Concurrent.Monad Haste.Concurrent.Ajax Haste.DOM.Core Haste.Events.BasicEvents Haste.Events.Core Haste.Events.KeyEvents Haste.Events.MouseEvents Haste.Events.TouchEvents Haste.Hash Haste.Random Haste.Timer }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11050#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11050: [bug] ModOrigin: hidden module redefined -------------------------------------+------------------------------------- Reporter: codeonwort | Owner: Type: bug | Status: new Priority: normal | Milestone: 8.0.1 Component: Compiler | Version: 7.10.2 Resolution: | Keywords: Operating System: Linux | Architecture: x86_64 Type of failure: Compile-time | (amd64) crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by thomie): I opened https://github.com/valderman/haste-compiler/issues/349 for this. I don't know for sure if it is a bug in haste or in ghc/ghc-pkg (maybe ghc-pkg should reject such packages from being installed at all, since ghc chokes on them anyway?). -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11050#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11050: [bug] ModOrigin: hidden module redefined -------------------------------------+------------------------------------- Reporter: codeonwort | Owner: Type: bug | Status: new Priority: normal | Milestone: 8.0.1 Component: ghc-pkg | Version: 7.10.2 Resolution: | Keywords: Operating System: Linux | Architecture: x86_64 Type of failure: Compile-time | (amd64) crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * component: Compiler => ghc-pkg -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11050#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC