[GHC] #4503: compiling ghc HEAD fails on GenericTemplate.hs, looking for XBangPatterns

GHC cvs-ghc at haskell.org
Wed Nov 17 19:59:33 EST 2010


#4503: compiling ghc HEAD fails on GenericTemplate.hs, looking for XBangPatterns
---------------------------+------------------------------------------------
  Reporter:  hasenov       |          Owner:                  
      Type:  bug           |         Status:  closed          
  Priority:  normal        |      Milestone:                  
 Component:  Compiler      |        Version:  7.1             
Resolution:  fixed         |       Keywords:                  
  Testcase:                |      Blockedby:                  
Difficulty:                |             Os:  Unknown/Multiple
  Blocking:                |   Architecture:  Unknown/Multiple
   Failure:  None/Unknown  |  
---------------------------+------------------------------------------------
Changes (by igloo):

  * status:  new => closed
  * resolution:  => fixed


Old description:

> After "./configure" I type in "make" on the command prompt. Here is the
> resulting output:
>
> [ecks at myhost ghc]$ make
> ===--- updating makefiles phase 0
> make -r --no-print-directory -f ghc.mk phase=0 just-makefiles
> ===--- updating makefiles phase 1
> make -r --no-print-directory -f ghc.mk phase=1 just-makefiles
> ===--- updating makefiles phase 2
> make -r --no-print-directory -f ghc.mk phase=2 just-makefiles
> ===--- updating makefiles phase 3
> make -r --no-print-directory -f ghc.mk phase=3 just-makefiles
> ===--- finished updating makefiles
> make -r --no-print-directory -f ghc.mk all
> "inplace/bin/ghc-stage1"   -H32m -O    -package-name ghc-7.1.20101116
> -hide-all-packages -i -icompiler/basicTypes -icompiler/cmm
> -icompiler/codeGen -icompiler/coreSyn -icompiler/deSugar -icompiler/ghci
> -icompiler/hsSyn -icompiler/iface -icompiler/llvmGen -icompiler/main
> -icompiler/nativeGen -icompiler/parser -icompiler/prelude
> -icompiler/profiling -icompiler/rename -icompiler/simplCore
> -icompiler/simplStg -icompiler/specialise -icompiler/stgSyn
> -icompiler/stranal -icompiler/typecheck -icompiler/types -icompiler/utils
> -icompiler/vectorise -icompiler/stage2/build
> -icompiler/stage2/build/autogen -Icompiler/stage2/build
> -Icompiler/stage2/build/autogen -Icompiler/../libffi/build/include
> -Icompiler/stage2 -Icompiler/../libraries/base/cbits
> -Icompiler/../libraries/base/include -Icompiler/. -Icompiler/parser
> -Icompiler/utils   -optP-DGHCI -optP-include
> -optPcompiler/stage2/build/autogen/cabal_macros.h -package Cabal-1.11.0
> -package array-0.3.0.2 -package base-4.3.0.0 -package bin-package-
> db-0.0.0.0 -package bytestring-0.9.1.8 -package containers-0.4.0.0
> -package directory-1.1.0.0 -package filepath-1.2.0.0 -package hpc-0.5.0.6
> -package old-time-1.0.0.6 -package process-1.0.1.4 -package template-
> haskell-2.5.0.0 -package unix-2.4.1.0  -Wall -fno-warn-name-shadowing
> -fno-warn-orphans -XCPP -XMagicHash -XUnboxedTuples -XPatternGuards
> -XForeignFunctionInterface -XEmptyDataDecls -XTypeSynonymInstances
> -XMultiParamTypeClasses -XFlexibleInstances -XRank2Types
> -XScopedTypeVariables -XDeriveDataTypeable -DGHCI_TABLES_NEXT_TO_CODE
> -DSTAGE=2 -no-user-package-conf -rtsopts -O2     -odir
> compiler/stage2/build -hidir compiler/stage2/build -stubdir
> compiler/stage2/build -hisuf hi -osuf  o -hcsuf hc -c
> compiler/stage2/build/Parser.hs -o compiler/stage2/build/Parser.o
>
> templates/GenericTemplate.hs:112:44:
>     Illegal bang-pattern (use -XBangPatterns):
>     ! (new_state)
> make[1]: *** [compiler/stage2/build/Parser.o] Error 1
> make: *** [all] Error 2
> [ecks at myhost ghc]$

New description:

 After "./configure" I type in "make" on the command prompt. Here is the
 resulting output:
 {{{
 [ecks at myhost ghc]$ make
 ===--- updating makefiles phase 0
 make -r --no-print-directory -f ghc.mk phase=0 just-makefiles
 ===--- updating makefiles phase 1
 make -r --no-print-directory -f ghc.mk phase=1 just-makefiles
 ===--- updating makefiles phase 2
 make -r --no-print-directory -f ghc.mk phase=2 just-makefiles
 ===--- updating makefiles phase 3
 make -r --no-print-directory -f ghc.mk phase=3 just-makefiles
 ===--- finished updating makefiles
 make -r --no-print-directory -f ghc.mk all
 "inplace/bin/ghc-stage1"   -H32m -O    -package-name ghc-7.1.20101116
 -hide-all-packages -i -icompiler/basicTypes -icompiler/cmm
 -icompiler/codeGen -icompiler/coreSyn -icompiler/deSugar -icompiler/ghci
 -icompiler/hsSyn -icompiler/iface -icompiler/llvmGen -icompiler/main
 -icompiler/nativeGen -icompiler/parser -icompiler/prelude
 -icompiler/profiling -icompiler/rename -icompiler/simplCore
 -icompiler/simplStg -icompiler/specialise -icompiler/stgSyn
 -icompiler/stranal -icompiler/typecheck -icompiler/types -icompiler/utils
 -icompiler/vectorise -icompiler/stage2/build
 -icompiler/stage2/build/autogen -Icompiler/stage2/build
 -Icompiler/stage2/build/autogen -Icompiler/../libffi/build/include
 -Icompiler/stage2 -Icompiler/../libraries/base/cbits
 -Icompiler/../libraries/base/include -Icompiler/. -Icompiler/parser
 -Icompiler/utils   -optP-DGHCI -optP-include
 -optPcompiler/stage2/build/autogen/cabal_macros.h -package Cabal-1.11.0
 -package array-0.3.0.2 -package base-4.3.0.0 -package bin-package-
 db-0.0.0.0 -package bytestring-0.9.1.8 -package containers-0.4.0.0
 -package directory-1.1.0.0 -package filepath-1.2.0.0 -package hpc-0.5.0.6
 -package old-time-1.0.0.6 -package process-1.0.1.4 -package template-
 haskell-2.5.0.0 -package unix-2.4.1.0  -Wall -fno-warn-name-shadowing
 -fno-warn-orphans -XCPP -XMagicHash -XUnboxedTuples -XPatternGuards
 -XForeignFunctionInterface -XEmptyDataDecls -XTypeSynonymInstances
 -XMultiParamTypeClasses -XFlexibleInstances -XRank2Types
 -XScopedTypeVariables -XDeriveDataTypeable -DGHCI_TABLES_NEXT_TO_CODE
 -DSTAGE=2 -no-user-package-conf -rtsopts -O2     -odir
 compiler/stage2/build -hidir compiler/stage2/build -stubdir
 compiler/stage2/build -hisuf hi -osuf  o -hcsuf hc -c
 compiler/stage2/build/Parser.hs -o compiler/stage2/build/Parser.o

 templates/GenericTemplate.hs:112:44:
     Illegal bang-pattern (use -XBangPatterns):
     ! (new_state)
 make[1]: *** [compiler/stage2/build/Parser.o] Error 1
 make: *** [all] Error 2
 [ecks at myhost ghc]$
 }}}

--

Comment:

 Thanks for the report. Fixed by
 {{{
 Wed Nov 17 11:37:05 GMT 2010  Simon Marlow <marlowsd at gmail.com>
   * add some {-# LANGUAGE BangPatterns #-} to mollify GHC
 }}}

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


More information about the Glasgow-haskell-bugs mailing list