diff --git a/Data/Encoding.hs b/Data/Encoding.hs index 380a237..51ecb35 100644 --- a/Data/Encoding.hs +++ b/Data/Encoding.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE ExistentialQuantification #-} module Data.Encoding (Encoding(..) ,EncodingException(..) diff --git a/Data/Encoding/Base.hs b/Data/Encoding/Base.hs index a0dfe00..151619b 100644 --- a/Data/Encoding/Base.hs +++ b/Data/Encoding/Base.hs @@ -1,4 +1,4 @@ -{-# OPTIONS -fglasgow-exts #-} +{-# LANGUAGE CPP,TemplateHaskell,DeriveDataTypeable #-} module Data.Encoding.Base (Encoding(..) diff --git a/Data/Encoding/CP1250.hs b/Data/Encoding/CP1250.hs index 6e89d19..68468a2 100644 --- a/Data/Encoding/CP1250.hs +++ b/Data/Encoding/CP1250.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1250 (CP1250(..)) where diff --git a/Data/Encoding/CP1251.hs b/Data/Encoding/CP1251.hs index b47ab76..7b8c543 100644 --- a/Data/Encoding/CP1251.hs +++ b/Data/Encoding/CP1251.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1251 (CP1251(..)) where diff --git a/Data/Encoding/CP1252.hs b/Data/Encoding/CP1252.hs index e8cc2bc..132a081 100644 --- a/Data/Encoding/CP1252.hs +++ b/Data/Encoding/CP1252.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1252 (CP1252(..)) where diff --git a/Data/Encoding/CP1253.hs b/Data/Encoding/CP1253.hs index de16de2..ef71b43 100644 --- a/Data/Encoding/CP1253.hs +++ b/Data/Encoding/CP1253.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1253 (CP1253(..)) where diff --git a/Data/Encoding/CP1254.hs b/Data/Encoding/CP1254.hs index 0e58dab..6ad454c 100644 --- a/Data/Encoding/CP1254.hs +++ b/Data/Encoding/CP1254.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1254 (CP1254(..)) where diff --git a/Data/Encoding/CP1255.hs b/Data/Encoding/CP1255.hs index d0f6f55..872f391 100644 --- a/Data/Encoding/CP1255.hs +++ b/Data/Encoding/CP1255.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1255 (CP1255(..)) where diff --git a/Data/Encoding/CP1256.hs b/Data/Encoding/CP1256.hs index b0eaf89..0ec9588 100644 --- a/Data/Encoding/CP1256.hs +++ b/Data/Encoding/CP1256.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1256 (CP1256(..)) where diff --git a/Data/Encoding/CP1257.hs b/Data/Encoding/CP1257.hs index ec73ae1..5aa0f38 100644 --- a/Data/Encoding/CP1257.hs +++ b/Data/Encoding/CP1257.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1257 (CP1257(..)) where diff --git a/Data/Encoding/CP1258.hs b/Data/Encoding/CP1258.hs index 29b18c3..33e6887 100644 --- a/Data/Encoding/CP1258.hs +++ b/Data/Encoding/CP1258.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.CP1258 (CP1258(..)) where diff --git a/Data/Encoding/GB18030.hs b/Data/Encoding/GB18030.hs index 234c5cd..24645b8 100644 --- a/Data/Encoding/GB18030.hs +++ b/Data/Encoding/GB18030.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP #-} {- | GB18030 is a chinese character encoding that is mandatory in china (if you - don\'t implement it, you\'re not allowed to sell your software there). -} diff --git a/Data/Encoding/GB18030Data.hs b/Data/Encoding/GB18030Data.hs index 7a0e04c..52dbe79 100644 --- a/Data/Encoding/GB18030Data.hs +++ b/Data/Encoding/GB18030Data.hs @@ -1,4 +1,4 @@ -{-# OPTIONS -fglasgow-exts #-} +{-# LANGUAGE CPP, MagicHash #-} module Data.Encoding.GB18030Data where import Data.ByteString(ByteString) diff --git a/Data/Encoding/Helper/Data.hs b/Data/Encoding/Helper/Data.hs index 1ce76cb..fede430 100644 --- a/Data/Encoding/Helper/Data.hs +++ b/Data/Encoding/Helper/Data.hs @@ -63,7 +63,7 @@ createModuleFromFile name str = createModule (readDecodeTable name str) createModule :: [(Char,[Word8])] -> [(Char,Char)] -> [(Int,Int)] -> String createModule mp ranges rranges = unlines $ - ["{-# OPTIONS -fglasgow-exts #-}" + ["{-# LANGUAGE CPP,MagicHash #-}" ,"module Data.Encoding.GB18030Data where" ,"" ,"import Data.ByteString(ByteString)" diff --git a/Data/Encoding/Helper/Template.hs b/Data/Encoding/Helper/Template.hs index 3d9850e..04a7494 100644 --- a/Data/Encoding/Helper/Template.hs +++ b/Data/Encoding/Helper/Template.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} {- This module is used to create arrays from lists in template haskell -} module Data.Encoding.Helper.Template where diff --git a/Data/Encoding/ISO88591.hs b/Data/Encoding/ISO88591.hs index 1ea84c2..d48e340 100644 --- a/Data/Encoding/ISO88591.hs +++ b/Data/Encoding/ISO88591.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} {- | Implements ISO\/IEC 8859-1 alias latin-1 encoding. See for further informations. -} diff --git a/Data/Encoding/ISO885910.hs b/Data/Encoding/ISO885910.hs index 57eac4f..a0f6d88 100644 --- a/Data/Encoding/ISO885910.hs +++ b/Data/Encoding/ISO885910.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO885910 (ISO885910(..)) where diff --git a/Data/Encoding/ISO885911.hs b/Data/Encoding/ISO885911.hs index 0ace8a0..47b256f 100644 --- a/Data/Encoding/ISO885911.hs +++ b/Data/Encoding/ISO885911.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO885911 (ISO885911(..)) where diff --git a/Data/Encoding/ISO885913.hs b/Data/Encoding/ISO885913.hs index 4d8a606..62ecb91 100644 --- a/Data/Encoding/ISO885913.hs +++ b/Data/Encoding/ISO885913.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO885913 (ISO885913(..)) where diff --git a/Data/Encoding/ISO885914.hs b/Data/Encoding/ISO885914.hs index cda80fc..9218409 100644 --- a/Data/Encoding/ISO885914.hs +++ b/Data/Encoding/ISO885914.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO885914 (ISO885914(..)) where diff --git a/Data/Encoding/ISO885915.hs b/Data/Encoding/ISO885915.hs index 9d0510a..409ae90 100644 --- a/Data/Encoding/ISO885915.hs +++ b/Data/Encoding/ISO885915.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO885915 (ISO885915(..)) where diff --git a/Data/Encoding/ISO885916.hs b/Data/Encoding/ISO885916.hs index 4825cb1..5fe6e4b 100644 --- a/Data/Encoding/ISO885916.hs +++ b/Data/Encoding/ISO885916.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO885916 (ISO885916(..)) where diff --git a/Data/Encoding/ISO88592.hs b/Data/Encoding/ISO88592.hs index 845262a..7e7a131 100644 --- a/Data/Encoding/ISO88592.hs +++ b/Data/Encoding/ISO88592.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} {- | Implements ISO\/IEC 8859-2 alias latin-2 encoding. See for further informations. -} diff --git a/Data/Encoding/ISO88593.hs b/Data/Encoding/ISO88593.hs index 0785042..ede28fe 100644 --- a/Data/Encoding/ISO88593.hs +++ b/Data/Encoding/ISO88593.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} {- | Implements ISO 8859-3 encoding, alias latin-3, alias south european -} module Data.Encoding.ISO88593 diff --git a/Data/Encoding/ISO88594.hs b/Data/Encoding/ISO88594.hs index 8d7b067..719821d 100644 --- a/Data/Encoding/ISO88594.hs +++ b/Data/Encoding/ISO88594.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO88594 (ISO88594(..)) where diff --git a/Data/Encoding/ISO88595.hs b/Data/Encoding/ISO88595.hs index c5ec887..c8f55f7 100644 --- a/Data/Encoding/ISO88595.hs +++ b/Data/Encoding/ISO88595.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO88595 (ISO88595(..)) where diff --git a/Data/Encoding/ISO88596.hs b/Data/Encoding/ISO88596.hs index b0888d4..be729cf 100644 --- a/Data/Encoding/ISO88596.hs +++ b/Data/Encoding/ISO88596.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO88596 (ISO88596(..)) where diff --git a/Data/Encoding/ISO88597.hs b/Data/Encoding/ISO88597.hs index 0d8c22f..0626ee4 100644 --- a/Data/Encoding/ISO88597.hs +++ b/Data/Encoding/ISO88597.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO88597 (ISO88597(..)) where diff --git a/Data/Encoding/ISO88598.hs b/Data/Encoding/ISO88598.hs index 5ef32e6..5cc15e6 100644 --- a/Data/Encoding/ISO88598.hs +++ b/Data/Encoding/ISO88598.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO88598 (ISO88598(..)) where diff --git a/Data/Encoding/ISO88599.hs b/Data/Encoding/ISO88599.hs index 0c7187f..2387edb 100644 --- a/Data/Encoding/ISO88599.hs +++ b/Data/Encoding/ISO88599.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE CPP,TemplateHaskell #-} module Data.Encoding.ISO88599 (ISO88599(..)) where