summaryrefslogtreecommitdiff
path: root/docs/users_guide
diff options
context:
space:
mode:
authorDimitrios Vytiniotis <dimitris@microsoft.com>2011-11-16 15:28:43 +0000
committerDimitrios Vytiniotis <dimitris@microsoft.com>2011-11-16 15:28:43 +0000
commit7ec5404a3fd277251a1ab353aa398adfc02b6d34 (patch)
tree78ff33800fad55d7dbb4e1b1732d4f82c4e092a2 /docs/users_guide
parentdb892577a2effc2266533e355dad2c40f9fd3be1 (diff)
parent1bbb89f3ab009367fcca84b73b351ddcf5be16a4 (diff)
downloadhaskell-ghc-constraint-solver.tar.gz
Merge branch 'master' of http://darcs.haskell.org/ghc into ghc-constraint-solverghc-constraint-solver
Diffstat (limited to 'docs/users_guide')
-rw-r--r--docs/users_guide/flags.xml9
-rwxr-xr-xdocs/users_guide/glasgow_exts.xml15
-rw-r--r--docs/users_guide/using.xml14
3 files changed, 35 insertions, 3 deletions
diff --git a/docs/users_guide/flags.xml b/docs/users_guide/flags.xml
index e765525c13..1245d25fde 100644
--- a/docs/users_guide/flags.xml
+++ b/docs/users_guide/flags.xml
@@ -1538,6 +1538,15 @@
</row>
<row>
+ <entry><option>-fpedantic-bottoms</option></entry>
+ <entry>Make GHC be more precise about its treatment of bottom (but see also
+ <option>-fno-state-hack</option>). In particular, GHC will not
+ eta-expand through a case expression.</entry>
+ <entry>dynamic</entry>
+ <entry><option>-fno-pedantic-bottoms</option></entry>
+ </row>
+
+ <row>
<entry><option>-fomit-interface-pragmas</option></entry>
<entry>Don't generate interface pragmas</entry>
<entry>dynamic</entry>
diff --git a/docs/users_guide/glasgow_exts.xml b/docs/users_guide/glasgow_exts.xml
index 6d1b293701..1eb041bc27 100755
--- a/docs/users_guide/glasgow_exts.xml
+++ b/docs/users_guide/glasgow_exts.xml
@@ -8344,12 +8344,21 @@ happen.
</programlisting>
<para>A <literal>SPECIALIZE</literal> pragma for a function can
- be put anywhere its type signature could be put.</para>
+ be put anywhere its type signature could be put. Moreover, you
+ can also <literal>SPECIALIZE</literal> an <emphasis>imported</emphasis>
+ provided it was given an <literal>INLINABLE</literal> pragma at its definition site
+ (<xref linkend="inlinable-pragma"/>)</para>
<para>A <literal>SPECIALIZE</literal> has the effect of generating
(a) a specialised version of the function and (b) a rewrite rule
- (see <xref linkend="rewrite-rules"/>) that rewrites a call to the
- un-specialised function into a call to the specialised one.</para>
+ (see <xref linkend="rewrite-rules"/>) that rewrites a call to
+ the un-specialised function into a call to the specialised one.
+ Moreover, given a <literal>SPECIALIZE</literal> pragma for a
+ function <literal>f</literal>, GHC will automatically create
+ specialisations for any type-class-overloaded functions called
+ by <literal>f</literal>, if they are in the same module as
+ the <literal>SPECIALIZE</literal> pragma, or if they are
+ <literal>INLINABLE</literal>; and so on, transitively.</para>
<para>The type in a SPECIALIZE pragma can be any type that is less
polymorphic than the type of the original function. In concrete terms,
diff --git a/docs/users_guide/using.xml b/docs/users_guide/using.xml
index 4cace1ee88..2837842a0e 100644
--- a/docs/users_guide/using.xml
+++ b/docs/users_guide/using.xml
@@ -1856,6 +1856,20 @@ f "2" = 2
<varlistentry>
<term>
+ <option>-fpedantic-bottoms</option>
+ <indexterm><primary><option>-fpedantic-bottoms</option></primary></indexterm>
+ </term>
+ <listitem>
+ <para>Make GHC be more precise about its treatment of bottom (but see also
+ <option>-fno-state-hack</option>). In particular, stop GHC
+ eta-expanding through a case expression, which is good for
+ performance, but bad if you are using <literal>seq</literal> on
+ partial applications.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term>
<option>-fomit-interface-pragmas</option>
<indexterm><primary><option>-fomit-interface-pragmas</option></primary></indexterm>
</term>