Proposal: Warn when using Enum instance of Float or Double

harry voldermort at
Sun Jun 16 09:26:05 CEST 2013

The Enum instances for Float and Double have dubious semantics which cause
endless confusion, e.g.,,,,
and many more.

I would therefore like to propose that the usage of an Enum instance of
Float or Double generate a compiler warning, such as "The Enum instance of
Float is subject to rounding errors". Deadline: 2 weeks.

Pedantic question: Should it be the Enum instance _of_ Float or _for_ Float?

View this message in context:
Sent from the Haskell - Libraries mailing list archive at

More information about the Libraries mailing list