[project @ 1998-04-28 09:06:43 by sof]
authorsof <unknown>
Tue, 28 Apr 1998 09:06:43 +0000 (09:06 +0000)
committersof <unknown>
Tue, 28 Apr 1998 09:06:43 +0000 (09:06 +0000)
pprId: restrict printing of inline pragma info to non-code settings

ghc/compiler/basicTypes/Id.lhs

index e9694d4..9d3028c 100644 (file)
@@ -637,12 +637,17 @@ pprId :: Outputable ty => GenId ty -> SDoc
 pprId Id {idUnique = u, idName = n, idInfo = info}
   = hcat [ppr n, pp_prags]
   where
-    pp_prags | opt_PprStyle_All = case inlinePragInfo info of
-                                    IMustNotBeINLINEd -> text "{n}"
-                                    IWantToBeINLINEd  -> text "{i}"
-                                    IMustBeINLINEd    -> text "{I}"
-                                    other             -> empty
-            | otherwise        = empty
+    pp_prags sty 
+      | opt_PprStyle_All && not (codeStyle sty) 
+      = (case inlinePragInfo info of
+           IMustNotBeINLINEd -> text "{n}"
+           IWantToBeINLINEd  -> text "{i}"
+           IMustBeINLINEd    -> text "{I}"
+           other             -> empty) sty
+
+      | otherwise        
+      = empty sty
+
 \end{code}
 
 \begin{code}