[GHC] #13072: Move large tuples to a separate module in base

GHC ghc-devs at haskell.org
Fri Jan 6 18:33:15 UTC 2017


#13072: Move large tuples to a separate module in base
-------------------------------------+-------------------------------------
        Reporter:  rwbarton          |                Owner:  rwbarton
            Type:  task              |               Status:  new
        Priority:  normal            |            Milestone:  8.2.1
       Component:  libraries/base    |              Version:  8.1
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by rwbarton):

 I fixed that specific issue with this change
 {{{
 diff --git a/compiler/typecheck/TcExpr.hs b/compiler/typecheck/TcExpr.hs
 index 39a8884..183f133 100644
 --- a/compiler/typecheck/TcExpr.hs
 +++ b/compiler/typecheck/TcExpr.hs
 @@ -72,6 +72,7 @@ import FastString
  import Control.Monad
  import Class(classTyCon)
  import UniqFM ( nonDetEltsUFM )
 +import LoadIface ( checkWiredInTyCon )
  import qualified GHC.LanguageExtensions as LangExt

  import Data.Function
 @@ -441,6 +442,7 @@ tcExpr expr@(ExplicitTuple tup_args boxity) res_ty
    | all tupArgPresent tup_args
    = do { let arity  = length tup_args
               tup_tc = tupleTyCon boxity arity
 +       ; checkWiredInTyCon tup_tc
         ; res_ty <- expTypeToType res_ty
         ; (coi, arg_tys) <- matchExpectedTyConApp tup_tc res_ty
                             -- Unboxed tuples have RuntimeRep vars, which
 we
 }}}
 but this doesn't seem like a great general approach, given that
 `tupleTyCon` is called from a fair number of places.

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


More information about the ghc-tickets mailing list