diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2012-10-02 15:20:05 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2012-10-02 15:20:05 +0100 |
commit | 4708d3838d1d76c4a6d153b3e3a42b97c7d2f9c3 (patch) | |
tree | 836dd5a22ba251ab2fc9c580c8d8135aae08fc3f /compiler/deSugar | |
parent | 74d65116e7c047215f79deb410029ba727c6df5e (diff) | |
parent | 815dcff13084fa5ffb43d743d08bb4f021ae2753 (diff) | |
download | haskell-4708d3838d1d76c4a6d153b3e3a42b97c7d2f9c3.tar.gz |
Merge branch 'tc-untouchables'
Diffstat (limited to 'compiler/deSugar')
-rw-r--r-- | compiler/deSugar/Coverage.lhs | 1 | ||||
-rw-r--r-- | compiler/deSugar/DsBinds.lhs | 10 | ||||
-rw-r--r-- | compiler/deSugar/DsExpr.lhs | 2 |
3 files changed, 7 insertions, 6 deletions
diff --git a/compiler/deSugar/Coverage.lhs b/compiler/deSugar/Coverage.lhs index 493ff0c13e..d92f2d1dd7 100644 --- a/compiler/deSugar/Coverage.lhs +++ b/compiler/deSugar/Coverage.lhs @@ -576,6 +576,7 @@ addTickHsExpr (HsWrap w e) = (addTickHsExpr e) -- explicitly no tick on inside addTickHsExpr e@(HsType _) = return e +addTickHsExpr HsHole = panic "addTickHsExpr.HsHole" -- Others dhould never happen in expression content. addTickHsExpr e = pprPanic "addTickHsExpr" (ppr e) diff --git a/compiler/deSugar/DsBinds.lhs b/compiler/deSugar/DsBinds.lhs index 4fa1ec00c9..95d36f3879 100644 --- a/compiler/deSugar/DsBinds.lhs +++ b/compiler/deSugar/DsBinds.lhs @@ -440,8 +440,9 @@ dsSpec mb_poly_rhs (L loc (SpecPrag poly_id spec_co spec_inl)) | otherwise = putSrcSpanDs loc $ - do { let poly_name = idName poly_id - ; spec_name <- newLocalName poly_name + do { uniq <- newUnique + ; let poly_name = idName poly_id + spec_name = mkClonedInternalName uniq poly_name ; (bndrs, ds_lhs) <- liftM collectBinders (dsHsWrapper spec_co (Var poly_id)) ; let spec_ty = mkPiTypes bndrs (exprType ds_lhs) @@ -740,10 +741,6 @@ dsEvTerm (EvCast tm co) -- 'v' is always a lifted evidence variable so it is -- unnecessary to call varToCoreExpr v here. -dsEvTerm (EvKindCast v co) - = do { v' <- dsEvTerm v - ; dsTcCoercion co $ (\_ -> v') } - dsEvTerm (EvDFunApp df tys tms) = do { tms' <- mapM dsEvTerm tms ; return (Var df `mkTyApps` tys `mkApps` tms') } dsEvTerm (EvCoercion co) = dsTcCoercion co mkEqBox @@ -833,6 +830,7 @@ ds_tc_coercion subst tc_co go (TcSymCo co) = mkSymCo (go co) go (TcTransCo co1 co2) = mkTransCo (go co1) (go co2) go (TcNthCo n co) = mkNthCo n (go co) + go (TcLRCo lr co) = mkLRCo lr (go co) go (TcInstCo co ty) = mkInstCo (go co) ty go (TcLetCo bs co) = ds_tc_coercion (ds_co_binds bs) co go (TcCastCo co1 co2) = mkCoCast (go co1) (go co2) diff --git a/compiler/deSugar/DsExpr.lhs b/compiler/deSugar/DsExpr.lhs index 8c53c1aea1..a7501594e6 100644 --- a/compiler/deSugar/DsExpr.lhs +++ b/compiler/deSugar/DsExpr.lhs @@ -216,6 +216,8 @@ dsExpr (HsLamCase arg matches@(MatchGroup _ rhs_ty)) dsExpr (HsApp fun arg) = mkCoreAppDs <$> dsLExpr fun <*> dsLExpr arg + +dsExpr HsHole = panic "dsExpr: HsHole" \end{code} Note [Desugaring vars] |