[GHC] #13831: GHCi ignores -fforce-recomp on first :reload when used with custom preprocessor

GHC ghc-devs at haskell.org
Thu Jun 15 04:31:18 UTC 2017


#13831: GHCi ignores -fforce-recomp on first :reload when used with custom
preprocessor
-------------------------------------+-------------------------------------
        Reporter:  SimonHengel       |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  GHCi              |              Version:  8.0.2
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------
Description changed by SimonHengel:

@@ -21,0 +21,2 @@
+ }}}
+ {{{
@@ -24,0 +26,2 @@
+ }}}
+ {{{

New description:

 Steps to reproduce:

 {{{#!bash
 #!/bin/bash
 # file preprocess.sh
 echo "main = putStrLn \"`date -u`\"" > "$3"
 echo "Reloaded!"
 }}}

 {{{#!hs
 -- file Main.hs
 {-# OPTIONS_GHC -fforce-recomp -F -pgmF preprocess.sh #-}
 }}}

 {{{
 $ chmod +x preprocess.sh
 $ PATH=.:$PATH ghci Main.hs -v0
 Reloaded!
 *Main> main
 Thu Jun 15 04:15:26 UTC 2017
 }}}
 {{{
 *Main> :reload
 *Main> main
 Thu Jun 15 04:15:26 UTC 2017
 }}}
 {{{
 *Main> :reload
 Reloaded!
 *Main> main
 Thu Jun 15 04:15:35 UTC 2017
 }}}

 As is evident from the output above, the first `:reload` got lost;
 {{{preprocessor.sh}}} is not executed at all.  The second `:reload` works
 as expected.

--

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


More information about the ghc-tickets mailing list