#7447: Stale .hi files affect compilation. -------------------------+-------------------------------------------------- Reporter: int-e | Owner: Type: bug | Status: new Priority: normal | Component: Compiler Version: 7.6.1 | Keywords: Os: Linux | Architecture: x86_64 (amd64) Failure: None/Unknown | Blockedby: Blocking: | Related: -------------------------+-------------------------------------------------- I saw the following odd behaviour while playing with the example from #7446. Strangely, whether the warning (unusuable UNPACK pragma) is printed or not depends on the presence and contents of a .hi file despite of {{{--fforce-recomp}}} and even if the source file was modified.
{{{ > rm -f Peaker.* > ghc --version The Glorious Glasgow Haskell Compilation System, version 7.6.1 > echo 'module Peaker(V(..)) where{ data V = V {-# UNPACK #-} !L; data L = L V }' > Peaker.hs > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' > rm Peaker.hi > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' > echo 'module Peaker(L(..)) where{ data V = V {-# UNPACK #-} !L; data L = L V }' > Peaker.hs > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) > rm Peaker.hi > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' > echo 'module Peaker(V(..)) where{ data V = V {-# UNPACK #-} !L; data L = L V }' > Peaker.hs > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' > rm Peaker.hi > ghc -fforce-recomp -O1 Peaker.hs [1 of 1] Compiling Peaker ( Peaker.hs, Peaker.o ) Peaker.hs:1:38: Warning: Ignoring unusable UNPACK pragma on the first argument of `V' In the definition of data constructor `V' In the data declaration for `V' }}} -- Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7447> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler _______________________________________________ Glasgow-haskell-bugs mailing list Glasgow-haskell-bugs@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs