diff options
author | Oleg Grenrus <oleg.grenrus@iki.fi> | 2020-02-10 20:33:33 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2020-02-14 05:31:16 -0500 |
commit | aa6086fdf53aef690369771def6cf1c31faa38e8 (patch) | |
tree | 16b159a2afc8f0f7dafbafd2e0213240283b2f9c | |
parent | 9f2c3677b3a08d8ea6c0d1f5fd51e43b7fcfe75b (diff) | |
download | haskell-aa6086fdf53aef690369771def6cf1c31faa38e8.tar.gz |
Add explicit LANGUAGE Safe to template-haskell
(cherry picked from commit a5e0f376821ca882880b03b07b451aa574e289ec)
9 files changed, 11 insertions, 3 deletions
diff --git a/libraries/ghc-boot-th/GHC/LanguageExtensions/Type.hs b/libraries/ghc-boot-th/GHC/LanguageExtensions/Type.hs index 3f22518769..a18b00e15e 100644 --- a/libraries/ghc-boot-th/GHC/LanguageExtensions/Type.hs +++ b/libraries/ghc-boot-th/GHC/LanguageExtensions/Type.hs @@ -8,7 +8,7 @@ -- -- A data type defining the language extensions supported by GHC. -- -{-# LANGUAGE DeriveGeneric #-} +{-# LANGUAGE DeriveGeneric, Safe #-} module GHC.LanguageExtensions.Type ( Extension(..) ) where import Prelude -- See note [Why do we import Prelude here?] diff --git a/libraries/template-haskell/Language/Haskell/TH.hs b/libraries/template-haskell/Language/Haskell/TH.hs index b818535576..693a80fc3d 100644 --- a/libraries/template-haskell/Language/Haskell/TH.hs +++ b/libraries/template-haskell/Language/Haskell/TH.hs @@ -4,6 +4,7 @@ For other documentation, refer to: <http://www.haskell.org/haskellwiki/Template_Haskell> -} +{-# LANGUAGE Safe #-} module Language.Haskell.TH( -- * The monad and its operations Q, diff --git a/libraries/template-haskell/Language/Haskell/TH/LanguageExtensions.hs b/libraries/template-haskell/Language/Haskell/TH/LanguageExtensions.hs index 2043e89f6a..2024b0a89c 100644 --- a/libraries/template-haskell/Language/Haskell/TH/LanguageExtensions.hs +++ b/libraries/template-haskell/Language/Haskell/TH/LanguageExtensions.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Safe #-} ----------------------------------------------------------------------------- -- | -- Module : Language.Haskell.TH.LanguageExtensions diff --git a/libraries/template-haskell/Language/Haskell/TH/Lib.hs b/libraries/template-haskell/Language/Haskell/TH/Lib.hs index 77c85d907c..0ec932d00b 100644 --- a/libraries/template-haskell/Language/Haskell/TH/Lib.hs +++ b/libraries/template-haskell/Language/Haskell/TH/Lib.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE Safe #-} + -- | -- Language.Haskell.TH.Lib contains lots of useful helper functions for -- generating and manipulating Template Haskell terms diff --git a/libraries/template-haskell/Language/Haskell/TH/Lib/Internal.hs b/libraries/template-haskell/Language/Haskell/TH/Lib/Internal.hs index 3a55f7a96a..e401ff3e60 100644 --- a/libraries/template-haskell/Language/Haskell/TH/Lib/Internal.hs +++ b/libraries/template-haskell/Language/Haskell/TH/Lib/Internal.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE Safe #-} + -- | -- Language.Haskell.TH.Lib.Internal exposes some additional functionality that -- is used internally in GHC's integration with Template Haskell. This is not a diff --git a/libraries/template-haskell/Language/Haskell/TH/Lib/Map.hs b/libraries/template-haskell/Language/Haskell/TH/Lib/Map.hs index b11139c2cb..27794dd735 100644 --- a/libraries/template-haskell/Language/Haskell/TH/Lib/Map.hs +++ b/libraries/template-haskell/Language/Haskell/TH/Lib/Map.hs @@ -1,4 +1,5 @@ {-# LANGUAGE BangPatterns #-} +{-# LANGUAGE Safe #-} -- This is a non-exposed internal module -- diff --git a/libraries/template-haskell/Language/Haskell/TH/Ppr.hs b/libraries/template-haskell/Language/Haskell/TH/Ppr.hs index d2e1855da2..8cf39c9af8 100644 --- a/libraries/template-haskell/Language/Haskell/TH/Ppr.hs +++ b/libraries/template-haskell/Language/Haskell/TH/Ppr.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Safe #-} -- | contains a prettyprinter for the -- Template Haskell datatypes diff --git a/libraries/template-haskell/Language/Haskell/TH/PprLib.hs b/libraries/template-haskell/Language/Haskell/TH/PprLib.hs index ac0679a93e..84315ac63b 100644 --- a/libraries/template-haskell/Language/Haskell/TH/PprLib.hs +++ b/libraries/template-haskell/Language/Haskell/TH/PprLib.hs @@ -1,4 +1,4 @@ -{-# LANGUAGE FlexibleInstances #-} +{-# LANGUAGE FlexibleInstances, Safe #-} -- | Monadic front-end to Text.PrettyPrint diff --git a/libraries/template-haskell/Language/Haskell/TH/Quote.hs b/libraries/template-haskell/Language/Haskell/TH/Quote.hs index d01d734e07..329741ebe9 100644 --- a/libraries/template-haskell/Language/Haskell/TH/Quote.hs +++ b/libraries/template-haskell/Language/Haskell/TH/Quote.hs @@ -1,4 +1,4 @@ -{-# LANGUAGE RankNTypes, ScopedTypeVariables #-} +{-# LANGUAGE RankNTypes, ScopedTypeVariables, Safe #-} {- | Module : Language.Haskell.TH.Quote Description : Quasi-quoting support for Template Haskell |