Duplicate warning declarations [GHC00711]
A Haskell entity, such as a type or a toplevel definition, can be declared to be deprecated using a pragma. It is, however, illegal to specify multiple deprecation warnings for the same entity.
Examples
Two deprecation warnings for same constant
In this example, two deprecation warnings have been given for the constant pi
. This is not allowed, and can be fixed by just specifying one deprecation message.
messages/GHC00711/doubleDeprecation/before/DoubleDeprecation.hs:4:16: error: [GHC00711]
Multiple warning declarations for ‘pi’
also at messages/GHC00711/doubleDeprecation/before/DoubleDeprecation.hs:3:1617

4  {# DEPRECATED pi "Chosen approximation turned out to be too imprecise." #}
 ^^
DoubleDeprecation.hs
Before
module DoubleDeprecation where
{# DEPRECATED pi "pi is deprecated." #}
{# DEPRECATED pi "Chosen approximation turned out to be too imprecise." #}
pi :: Int
pi = 3
After
module DoubleDeprecation where
{# DEPRECATED pi "pi is deprecated. Chosen approximation turned out to be too imprecise." #}
pi :: Int
pi = 3