[GHC] #13927: Panic!

GHC ghc-devs at haskell.org
Wed Jul 5 15:15:02 UTC 2017


#13927: Panic!
-------------------------------------+-------------------------------------
        Reporter:  Deus              |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.0.1
      Resolution:                    |             Keywords:
Operating System:  Linux             |         Architecture:  x86_64
 Type of failure:  Compile-time      |  (amd64)
  crash or panic                     |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by RyanGlScott):

 This is a duplicate of #13106. It panics in 8.0.2 (you need to compile
 with `ghc`, not `ghci`) but not in GHC 8.2.1:

 {{{
 $ /opt/ghc/8.2.1/bin/ghc -fforce-recomp Bug.hs
 [1 of 1] Compiling Main             ( Bug.hs, Bug.o )

 Bug.hs:1:1: error:
     The IO action ‘main’ is not defined in module ‘Main’
   |
 1 | data Farbe = Rot | Rosa | Weis | Blau | Lila | Grun | Gelb
   | ^

 Bug.hs:46:16: error:
     • Variable not in scope: true :: Bool
     • Perhaps you meant data constructor ‘True’ (imported from Prelude)
    |
 46 | istrosa Rosa = true
    |                ^^^^

 Bug.hs:47:21: error:
     • Variable not in scope: false :: Bool
     • Perhaps you meant data constructor ‘False’ (imported from Prelude)
    |
 47 | istrosa otherwise = false
    |                     ^^^^^

 Bug.hs:53:42: error:
     • Variable not in scope: true :: Bool
     • Perhaps you meant data constructor ‘True’ (imported from Prelude)
    |
 53 | rosabluhend p = fold_pflanze und istrosa true p
    |                                          ^^^^
 }}}

 Alternatively, you can make the panic go away by just adding `module Plant
 where` at the top of the file.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13927#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list