[commit: ghc] master: fix syntax error in generated C (#7407) (80269ef)

Simon Marlow <[email protected]>
Newsgroups gmane.comp.lang.haskell.cvs.ghc
Message-ID <[email protected]>
Repository : ssh://darcs.haskell.org//srv/darcs/ghc

On branch  : master

http://hackage.haskell.org/trac/ghc/changeset/80269ef4899252e22319e9223b6c50df5600ccd3

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

commit 80269ef4899252e22319e9223b6c50df5600ccd3
Author: Simon Marlow <[email protected]>
Date:   Fri Nov 16 13:54:52 2012 +0000

    fix syntax error in generated C (#7407)

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

 compiler/cmm/PprC.hs |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/compiler/cmm/PprC.hs b/compiler/cmm/PprC.hs
index 1fe3872..4e73ade 100644
--- a/compiler/cmm/PprC.hs
+++ b/compiler/cmm/PprC.hs
@@ -295,8 +295,8 @@ pprBranch ident = ptext (sLit "goto") <+> pprBlockId ident <> semi
 pprCondBranch :: CmmExpr -> BlockId -> BlockId -> SDoc
 pprCondBranch expr yes no
         = hsep [ ptext (sLit "if") , parens(pprExpr expr) ,
-                        ptext (sLit "goto"), pprBlockId yes,
-                        ptext (sLit "else"), pprBlockId no <> semi ]
+                        ptext (sLit "goto"), pprBlockId yes <> semi,
+                        ptext (sLit "else goto"), pprBlockId no <> semi ]
 
 -- ---------------------------------------------------------------------
 -- a local table branch
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.