X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fdocs%2Fusers_guide%2Fglasgow_exts.xml;h=c9dfaf0a12ebc574b964f12222d9f60772bb0a72;hb=8bbcb41030b261c5070593d31760a01216dea441;hp=8a8b999cbabffbbd794ec11edc948dc3bbece8e3;hpb=78b72ed1e0ffab668e0d4bb31657942970515e4f;p=ghc-hetmet.git
diff --git a/ghc/docs/users_guide/glasgow_exts.xml b/ghc/docs/users_guide/glasgow_exts.xml
index 8a8b999..c9dfaf0 100644
--- a/ghc/docs/users_guide/glasgow_exts.xml
+++ b/ghc/docs/users_guide/glasgow_exts.xml
@@ -4638,6 +4638,29 @@ key_function :: Int -> String -> (Bool, Double)
+
+ LANGUAGE pragma
+
+ LANGUAGEpragma
+ pragmaLANGUAGE
+
+ This allows language extensions to be enabled in a portable way.
+ It is the intention that all Haskell compilers support the
+ LANGUAGE pragma with the same syntax, although not
+ all extensions are supported by all compilers, of
+ course. The LANGUAGE pragma should be used instead
+ of OPTIONS_GHC, if possible.
+
+ For example, to enable the FFI and preprocessing with CPP:
+
+{-# LANGUAGE ForeignFunctionInterface, CPP #-}
+
+ Any extension from the Extension type defined in
+ Language.Haskell.Extension may be used. GHC will report an error if any of the requested extensions are not supported.
+
+
+
LINE pragma
@@ -4648,9 +4671,7 @@ key_function :: Int -> String -> (Bool, Double)
code. It lets you specify the line number and filename of the
original code; for example
-
-{-# LINE 42 "Foo.vhs" #-}
-
+{-# LINE 42 "Foo.vhs" #-}
if you'd generated the current file from something called
Foo.vhs and this line corresponds to line