[commit: ghc] master: Remove whitespace between macro identifiers and `(` (9641641)

git at git.haskell.org git at git.haskell.org
Fri Nov 29 08:10:08 UTC 2013


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/96416412cc8100bd1c1625e10c09df17c88a67b7/ghc

>---------------------------------------------------------------

commit 96416412cc8100bd1c1625e10c09df17c88a67b7
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date:   Fri Nov 29 09:00:57 2013 +0100

    Remove whitespace between macro identifiers and `(`
    
    This is a kludge to workaround Clang's CPP lacking traditional-mode CPP
    
    (This was reported by Kazu Yamamoto)
    
    Signed-off-by: Herbert Valerio Riedel <hvr at gnu.org>


>---------------------------------------------------------------

96416412cc8100bd1c1625e10c09df17c88a67b7
 compiler/coreSyn/CoreUtils.lhs     |    4 ++--
 compiler/deSugar/DsBinds.lhs       |    2 +-
 compiler/typecheck/TcCanonical.lhs |    2 +-
 compiler/typecheck/TcEvidence.lhs  |    8 ++++----
 compiler/typecheck/TcSMonad.lhs    |    2 +-
 5 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/compiler/coreSyn/CoreUtils.lhs b/compiler/coreSyn/CoreUtils.lhs
index 91f68a2..40ce5ed 100644
--- a/compiler/coreSyn/CoreUtils.lhs
+++ b/compiler/coreSyn/CoreUtils.lhs
@@ -190,8 +190,8 @@ applyTypeToArgs e op_ty args
 -- | Wrap the given expression in the coercion safely, dropping
 -- identity coercions and coalescing nested coercions
 mkCast :: CoreExpr -> Coercion -> CoreExpr
-mkCast e co | ASSERT2 ( coercionRole co == Representational
-                      , ptext (sLit "coercion") <+> ppr co <+> ptext (sLit "passed to mkCast") <+> ppr e <+> ptext (sLit "has wrong role") <+> ppr (coercionRole co) )
+mkCast e co | ASSERT2( coercionRole co == Representational
+                     , ptext (sLit "coercion") <+> ppr co <+> ptext (sLit "passed to mkCast") <+> ppr e <+> ptext (sLit "has wrong role") <+> ppr (coercionRole co) )
               isReflCo co = e
 
 mkCast (Coercion e_co) co 
diff --git a/compiler/deSugar/DsBinds.lhs b/compiler/deSugar/DsBinds.lhs
index 9866453..5764d11 100644
--- a/compiler/deSugar/DsBinds.lhs
+++ b/compiler/deSugar/DsBinds.lhs
@@ -705,7 +705,7 @@ dsHsWrapper (WpTyApp ty)      e = return $ App e (Type ty)
 dsHsWrapper (WpLet ev_binds)  e = do bs <- dsTcEvBinds ev_binds
                                      return (mkCoreLets bs e)
 dsHsWrapper (WpCompose c1 c2) e = dsHsWrapper c1 =<< dsHsWrapper c2 e
-dsHsWrapper (WpCast co)       e = ASSERT (tcCoercionRole co == Representational)
+dsHsWrapper (WpCast co)       e = ASSERT(tcCoercionRole co == Representational)
                                   dsTcCoercion co (mkCast e)
 dsHsWrapper (WpEvLam ev)      e = return $ Lam ev e 
 dsHsWrapper (WpTyLam tv)      e = return $ Lam tv e 
diff --git a/compiler/typecheck/TcCanonical.lhs b/compiler/typecheck/TcCanonical.lhs
index d51fbf6..8f60bc5 100644
--- a/compiler/typecheck/TcCanonical.lhs
+++ b/compiler/typecheck/TcCanonical.lhs
@@ -1132,7 +1132,7 @@ canEqLeafTyVar ev tv s2              -- ev :: tv ~ s2
 
            (Just tv1, Just tv2) | tv1 == tv2
               -> do { when (isWanted ev) $
-                      ASSERT ( tcCoercionRole co == Nominal )
+                      ASSERT( tcCoercionRole co == Nominal )
                       setEvBind (ctev_evar ev) (mkEvCast (EvCoercion (mkTcReflCo Nominal xi1)) (mkTcSubCo co))
                     ; return Stop }
 
diff --git a/compiler/typecheck/TcEvidence.lhs b/compiler/typecheck/TcEvidence.lhs
index 6b1ee3e..c233d71 100644
--- a/compiler/typecheck/TcEvidence.lhs
+++ b/compiler/typecheck/TcEvidence.lhs
@@ -149,7 +149,7 @@ mkTcTyConAppCo role tc cos -- No need to expand type synonyms
 -- mkSubCo will do some normalisation. We do not do it for TcCoercions, but
 -- defer that to desugaring; just to reduce the code duplication a little bit
 mkTcSubCo :: TcCoercion -> TcCoercion
-mkTcSubCo co = ASSERT2 ( tcCoercionRole co == Nominal, ppr co)
+mkTcSubCo co = ASSERT2( tcCoercionRole co == Nominal, ppr co)
                TcSubCo co
 
 maybeTcSubCo2_maybe :: Role   -- desired role
@@ -171,7 +171,7 @@ maybeTcSubCo2 r1 r2 co
 
 mkTcAxInstCo :: Role -> CoAxiom br -> Int -> [TcType] -> TcCoercion
 mkTcAxInstCo role ax index tys
-  | ASSERT2 ( not (role == Nominal && ax_role == Representational) , ppr (ax, tys) )
+  | ASSERT2( not (role == Nominal && ax_role == Representational) , ppr (ax, tys) )
     arity == n_tys = maybeTcSubCo2 role ax_role $ TcAxiomInstCo ax_br index rtys
   | otherwise      = ASSERT( arity < n_tys )
                      maybeTcSubCo2 role ax_role $ 
@@ -486,7 +486,7 @@ c <.> WpHole = c
 c1 <.> c2    = c1 `WpCompose` c2
 
 mkWpCast :: TcCoercion -> HsWrapper
-mkWpCast co = ASSERT2 (tcCoercionRole co == Representational, ppr co)
+mkWpCast co = ASSERT2(tcCoercionRole co == Representational, ppr co)
               WpCast co
 
 mkWpTyApps :: [Type] -> HsWrapper
@@ -709,7 +709,7 @@ The story for kind `Symbol` is analogous:
 \begin{code}
 mkEvCast :: EvTerm -> TcCoercion -> EvTerm
 mkEvCast ev lco
-  | ASSERT2 (tcCoercionRole lco == Representational, (vcat [ptext (sLit "Coercion of wrong role passed to mkEvCast:"), ppr ev, ppr lco]))
+  | ASSERT2(tcCoercionRole lco == Representational, (vcat [ptext (sLit "Coercion of wrong role passed to mkEvCast:"), ppr ev, ppr lco]))
     isTcReflCo lco = ev
   | otherwise      = EvCast ev lco
 
diff --git a/compiler/typecheck/TcSMonad.lhs b/compiler/typecheck/TcSMonad.lhs
index 90fe446..06856d7 100644
--- a/compiler/typecheck/TcSMonad.lhs
+++ b/compiler/typecheck/TcSMonad.lhs
@@ -1708,7 +1708,7 @@ rewriteCtFlavor (CtGiven { ctev_evtm = old_tm , ctev_loc = loc }) new_pred co
 
 rewriteCtFlavor (CtWanted { ctev_evar = evar, ctev_loc = loc }) new_pred co
   = do { new_evar <- newWantedEvVar loc new_pred
-       ; MASSERT ( tcCoercionRole co == Nominal )
+       ; MASSERT( tcCoercionRole co == Nominal )
        ; setEvBind evar (mkEvCast (getEvTerm new_evar) (mkTcSubCo co))
        ; case new_evar of
             Fresh ctev -> return (Just ctev)



More information about the ghc-commits mailing list