#5795: Breaking the staging restriction in type splices causes GHC panic
------------------------------+---------------------------------------------
 Reporter:  reinerp           |          Owner:                  
     Type:  bug               |         Status:  new             
 Priority:  normal            |      Component:  Template Haskell
  Version:  7.4.1-rc1         |       Keywords:                  
       Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
  Failure:  None/Unknown      |       Testcase:                  
Blockedby:                    |       Blocking:                  
  Related:                    |  
------------------------------+---------------------------------------------
 Test case:
 {{{
 {-# LANGUAGE TemplateHaskell #-}
 module B where

 import Language.Haskell.TH

 ty :: Q Type
 ty = [t| Int |]

 f :: $ty
 f = undefined
 }}}

 The error message is:

 {{{

 B.hs:9:6:
     GHC internal error: `ty' is not in scope during type checking, but it
 passed the renamer
     tcl_env of environment: []
     In the expression: ty
     In the type signature for `f': f :: $ty
 }}}

 This is the same error as in #5792.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/5795>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to