summaryrefslogtreecommitdiff
path: root/compiler/specialise
diff options
context:
space:
mode:
authorHerbert Valerio Riedel <hvr@gnu.org>2014-05-14 19:46:28 +0200
committerHerbert Valerio Riedel <hvr@gnu.org>2014-05-15 10:27:05 +0200
commit23892440032fcab8a6a753916d506857674169ec (patch)
treeab4da76e40f21984bd3cdb774f3baf8787461045 /compiler/specialise
parente199891f199795468cdcf977d5395d3c846cad72 (diff)
downloadhaskell-23892440032fcab8a6a753916d506857674169ec.tar.gz
Add LANGUAGE pragmas to compiler/ source files
In some cases, the layout of the LANGUAGE/OPTIONS_GHC lines has been reorganized, while following the convention, to - place `{-# LANGUAGE #-}` pragmas at the top of the source file, before any `{-# OPTIONS_GHC #-}`-lines. - Moreover, if the list of language extensions fit into a single `{-# LANGUAGE ... -#}`-line (shorter than 80 characters), keep it on one line. Otherwise split into `{-# LANGUAGE ... -#}`-lines for each individual language extension. In both cases, try to keep the enumeration alphabetically ordered. (The latter layout is preferable as it's more diff-friendly) While at it, this also replaces obsolete `{-# OPTIONS ... #-}` pragma occurences by `{-# OPTIONS_GHC ... #-}` pragmas.
Diffstat (limited to 'compiler/specialise')
-rw-r--r--compiler/specialise/Rules.lhs2
-rw-r--r--compiler/specialise/SpecConstr.lhs2
-rw-r--r--compiler/specialise/Specialise.lhs2
3 files changed, 6 insertions, 0 deletions
diff --git a/compiler/specialise/Rules.lhs b/compiler/specialise/Rules.lhs
index 70fc09a2ef..2abf7fbdca 100644
--- a/compiler/specialise/Rules.lhs
+++ b/compiler/specialise/Rules.lhs
@@ -4,6 +4,8 @@
\section[CoreRules]{Transformation rules}
\begin{code}
+{-# LANGUAGE CPP #-}
+
-- | Functions for collecting together and applying rewrite rules to a module.
-- The 'CoreRule' datatype itself is declared elsewhere.
module Rules (
diff --git a/compiler/specialise/SpecConstr.lhs b/compiler/specialise/SpecConstr.lhs
index 9df460edde..24820eba40 100644
--- a/compiler/specialise/SpecConstr.lhs
+++ b/compiler/specialise/SpecConstr.lhs
@@ -9,6 +9,8 @@ ToDo [Oct 2013]
\section[SpecConstr]{Specialise over constructors}
\begin{code}
+{-# LANGUAGE CPP #-}
+
module SpecConstr(
specConstrProgram
#ifdef GHCI
diff --git a/compiler/specialise/Specialise.lhs b/compiler/specialise/Specialise.lhs
index 3191ae946e..baa5d1971f 100644
--- a/compiler/specialise/Specialise.lhs
+++ b/compiler/specialise/Specialise.lhs
@@ -4,6 +4,8 @@
\section[Specialise]{Stamping out overloading, and (optionally) polymorphism}
\begin{code}
+{-# LANGUAGE CPP #-}
+
module Specialise ( specProgram ) where
#include "HsVersions.h"