diff options
author | Nickolai Zeldovich <nickolai@csail.mit.edu> | 2014-09-16 14:56:59 +0000 |
---|---|---|
committer | Pierre Boutillier <pierre.boutillier@ens-lyon.org> | 2014-10-28 09:09:56 +0100 |
commit | 53bfe9cf58a3c40e6eb7120d25c1633a9cea3126 (patch) | |
tree | 833294862be5e6df5db2e766208c90028daaf217 /plugins/extraction | |
parent | 1545317ea8b6e7ca4965f06f00bc524d5af1ef47 (diff) |
Haskell extraction: use explicit -XMagicHash instead of -fglasgow-exts
When Coq's Haskell extraction needs to use unsafeCoerce, it passes
the -fglasgow-exts option to GHC, but recent versions of GHC warn
against this:
xx.hs:1:16: Warning:
-fglasgow-exts is deprecated: Use individual extensions instead
This patch does as the warning suggests, replacing -fglasgow-exts
with the specific option that the extraction needs (-XMagicHash).
Diffstat (limited to 'plugins/extraction')
-rw-r--r-- | plugins/extraction/haskell.ml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/extraction/haskell.ml b/plugins/extraction/haskell.ml index 6008dffde..e63cdfb68 100644 --- a/plugins/extraction/haskell.ml +++ b/plugins/extraction/haskell.ml @@ -40,7 +40,7 @@ let preamble mod_name comment used_modules usf = in (if not usf.magic then mt () else - str "{-# OPTIONS_GHC -cpp -fglasgow-exts #-}" ++ fnl () ++ + str "{-# OPTIONS_GHC -cpp -XMagicHash #-}" ++ fnl () ++ str "{- For Hugs, use the option -F\"cpp -P -traditional\" -}") ++ fnl () ++ fnl () ++ |