</varlistentry>
<varlistentry>
+ <term><option>-fwarn-identities</option>:</term>
+ <listitem>
+ <indexterm><primary><option>-fwarn-identities</option></primary></indexterm>
+ <para>Causes the compiler to emit a warning when a Prelude numeric
+ conversion converts a type T to the same type T; such calls
+ are probably no-ops and can be omitted. The functions checked for
+ are: <literal>toInteger</literal>,
+ <literal>toRational</literal>,
+ <literal>fromIntegral</literal>,
+ and <literal>realToFrac</literal>.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><option>-fwarn-implicit-prelude</option>:</term>
<listitem>
<indexterm><primary><option>-fwarn-implicit-prelude</option></primary></indexterm>
<indexterm><primary>incomplete patterns, warning</primary></indexterm>
<indexterm><primary>patterns, incomplete</primary></indexterm>
- <para>Similarly for incomplete patterns, the function
- <function>g</function> below will fail when applied to
+ <para>Similarly for incomplete patterns, the functions
+ <function>g</function> and <function>h</function> below will fail when applied to
non-empty lists, so the compiler will emit a warning about
this when <option>-fwarn-incomplete-patterns</option> is
enabled.</para>
<programlisting>
g [] = 2
+h = \[] -> 2
</programlisting>
<para>This option isn't enabled by default because it can be
<option>-O</option>.</para>
</listitem>
</varlistentry>
-
- <varlistentry>
- <term>
- <option>-Ofile <file></option>:
- <indexterm><primary>-Ofile <file> option</primary></indexterm>
- <indexterm><primary>optimising, customised</primary></indexterm>
- </term>
- <listitem>
- <para>(NOTE: not supported since GHC 4.x. Please ask if
- you're interested in this.)</para>
-
- <para>For those who need <emphasis>absolute</emphasis>
- control over <emphasis>exactly</emphasis> what options are
- used (e.g., compiler writers, sometimes :-), a list of
- options can be put in a file and then slurped in with
- <option>-Ofile</option>.</para>
-
- <para>In that file, comments are of the
- <literal>#</literal>-to-end-of-line variety; blank
- lines and most whitespace is ignored.</para>
-
- <para>Please ask if you are baffled and would like an
- example of <option>-Ofile</option>!</para>
- </listitem>
- </varlistentry>
</variablelist>
<para>We don't use a <option>-O*</option> flag for day-to-day