[Haskell-cafe] record field names vs. -fwarn-unused-binds
Michael Orlitzky
michael at orlitzky.com
Wed Nov 4 15:08:32 UTC 2015
On 11/04/2015 09:56 AM, Henning Thielemann wrote:
>
> On Tue, 3 Nov 2015, Evan Laforge wrote:
>
>> I can work around by putting underscores on field names I haven't used
>> yet, but it's a hassle to go edit them when I want to use them.
>
> I do it this way and I do not consider it a work-around. The underscore is
> just the shortest way to say that a record field name is not used. It's
> shorter than any pragma could be.
There are libraries that do magic based on the field name (Groundhog
comes to mind). In those cases you have to name the field appropriately
even if you're not going to use it, so the ability to shutup the warning
will be appreciated.
More information about the Haskell-Cafe
mailing list