[Haskell-cafe] Cmdargs and common flags

Neil Mitchell ndmitchell at gmail.com
Sat Mar 12 22:30:07 CET 2011


{-# OPTIONS_GHC -fno-warn-missing-fields #-}

That's what I did in my CmdArgs test suite - if you have all your
CmdArgs bit in a separate file then missing this warning will be fine.
I don't know of any way to rewrite the code to indicate to GHC that
you know what you are doing.

Thanks, Neil


On Sat, Mar 12, 2011 at 8:02 AM, Magnus Therning <magnus at therning.org> wrote:
> On Mon, Feb 14, 2011 at 19:11, Neil Mitchell <ndmitchell at gmail.com> wrote:
>> Hi Magnus,
>>
>>> Finally, you can switch to the pure annotations. I will document them
>>> shortly and give an example in System.Console.CmdArgs.Implicit, but
>>> for now the details can be found at
>>> http://hackage.haskell.org/packages/archive/cmdargs/0.6.7/doc/html/System-Console-CmdArgs-Annotate.html
>>
>> I've added more details in:
>> http://hackage.haskell.org/packages/archive/cmdargs/0.6.8/doc/html/System-Console-CmdArgs-Annotate.html
>> http://hackage.haskell.org/packages/archive/cmdargs/0.6.8/doc/html/System-Console-CmdArgs-Implicit.html
>>
>> The first link includes comparisons for pure/impure, and the second
>> gives a set of equivalences for converting between the two forms.
>>
>> Thanks, Neil
>
> I noticed that the form "record Ctor {} [...]" leads to a warning that
> Ctor isn't initialised.  The obvious way to remove the warning is to
> call the constructor with all the arguments, but is there a more
> convenient/terse way of achieving the same?
>
> /M
>
> --
> Magnus Therning                      OpenPGP: 0xAB4DFBA4
> email: magnus at therning.org   jabber: magnus at therning.org
> twitter: magthe               http://therning.org/magnus
>



More information about the Haskell-Cafe mailing list