diff --git a/src/Data/Singletons/Prelude/Ord/Disambiguation.hs b/src/Data/Singletons/Prelude/Ord/Disambiguation.hs index c32648f9..95666bc6 100644 --- a/src/Data/Singletons/Prelude/Ord/Disambiguation.hs +++ b/src/Data/Singletons/Prelude/Ord/Disambiguation.hs @@ -16,7 +16,8 @@ -- Stability : experimental -- Portability : non-portable -- --- TODO RGS +-- Provides aliases for 'Min' and 'Max' that do not clash with the data +-- types of the same names in Data.Singletons.Prelude.Semigroup. -- ---------------------------------------------------------------------------- diff --git a/src/Data/Singletons/Prelude/Semigroup/Internal/Disambiguation.hs b/src/Data/Singletons/Prelude/Semigroup/Internal/Disambiguation.hs index afa1ba92..4b8352a1 100644 --- a/src/Data/Singletons/Prelude/Semigroup/Internal/Disambiguation.hs +++ b/src/Data/Singletons/Prelude/Semigroup/Internal/Disambiguation.hs @@ -16,7 +16,9 @@ -- Stability : experimental -- Portability : non-portable -- --- TODO RGS +-- Provides aliases for 'All', 'Any', 'Sum', and 'Product' that do not clash +-- with the promoted functions of the same names in +-- Data.Singletons.Prelude.Foldable. -- ---------------------------------------------------------------------------- @@ -26,7 +28,11 @@ import Data.Semigroup import Data.Singletons.Prelude.Semigroup.Internal import Data.Singletons.Single --- We need these in Data.Singletons.Prelude.Foldable. +-- We need these in Data.Singletons.Prelude.Foldable, as we need to promote +-- code that simultaneously uses the All/Any/Sum/Product constructors and the +-- all/any/sum/product functions, which have clashing defunctionalization +-- symbol names. Our workaround is to simply define synonyms for +-- all/any/sum/product and use those instead. $(singletons [d| all_ :: Bool -> All all_ = All