Skip to content

Commit

Permalink
Redo Monoid&Semigroup again.
Browse files Browse the repository at this point in the history
  • Loading branch information
augustss committed Sep 22, 2024
1 parent 52b1295 commit e310260
Show file tree
Hide file tree
Showing 19 changed files with 190 additions and 288 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ MRUNTIME=$(MDATA)/src/runtime
MCABALBIN=$(MCABAL)/bin
MDIST=dist-mcabal
BASE=base-$(VERSION)
BASEMODULES=Control.Applicative Control.Arrow Control.Category Control.DeepSeq Control.Error Control.Exception Control.Monad Control.Monad.Fail Control.Monad.Fix Control.Monad.ST Control.Monad.Zip Data.Array Data.Bits Data.Bool Data.Bounded Data.ByteString Data.Char Data.Complex Data.Constraint Data.Data Data.Double Data.Dynamic Data.Either Data.Enum Data.Eq Data.Float Data.FloatW Data.Floating Data.Foldable Data.Fractional Data.Function Data.Functor Data.Functor.Classes Data.Functor.Compose Data.Functor.Const Data.Functor.Identity Data.Functor.Product Data.Functor.Sum Data.IOArray Data.IORef Data.Int Data.Integer Data.Integral Data.Ix Data.List Data.List.NonEmpty Data.Maybe Data.Monoid Data.Num Data.Ord Data.Proxy Data.Ratio Data.Real Data.RealFloat Data.RealFrac Data.Records Data.STRef Data.Semigroup Data.String Data.Text Data.Time.Clock Data.Time.Format Data.Traversable Data.Tuple Data.Type.Equality Data.TypeLits Data.Typeable Data.Version Data.Void Data.Word Data.ZipList Debug.Trace Foreign.C.String Foreign.C.Types Foreign.ForeignPtr Foreign.Marshal.Alloc Foreign.Marshal.Array Foreign.Marshal.Utils Foreign.Ptr Foreign.Storable GHC.Stack GHC.Types Numeric Numeric.FormatFloat Numeric.Natural Prelude System.Cmd System.Compress System.Directory System.Environment System.Exit System.IO System.IO.MD5 System.IO.PrintOrRun System.IO.Serialize System.IO.TimeMilli System.IO.Unsafe System.Info System.Process Text.Printf Text.ParserCombinators.ReadP Text.ParserCombinators.ReadPrec Text.Read Text.Read.Lex Text.Show TimeCompat Unsafe.Coerce
BASEMODULES=Control.Applicative Control.Arrow Control.Category Control.DeepSeq Control.Error Control.Exception Control.Monad Control.Monad.Fail Control.Monad.Fix Control.Monad.ST Control.Monad.Zip Data.Array Data.Bits Data.Bool Data.Bounded Data.ByteString Data.Char Data.Complex Data.Constraint Data.Data Data.Double Data.Dynamic Data.Either Data.Enum Data.Eq Data.Float Data.FloatW Data.Floating Data.Foldable Data.Foldable1 Data.Fractional Data.Function Data.Functor Data.Functor.Classes Data.Functor.Compose Data.Functor.Const Data.Functor.Identity Data.Functor.Product Data.Functor.Sum Data.IOArray Data.IORef Data.Int Data.Integer Data.Integral Data.Ix Data.List Data.List.NonEmpty Data.Maybe Data.Monoid Data.Num Data.Ord Data.Proxy Data.Ratio Data.Real Data.RealFloat Data.RealFrac Data.Records Data.STRef Data.Semigroup Data.String Data.Text Data.Time.Clock Data.Time.Format Data.Traversable Data.Tuple Data.Type.Equality Data.TypeLits Data.Typeable Data.Version Data.Void Data.Word Data.ZipList Debug.Trace Foreign.C.String Foreign.C.Types Foreign.ForeignPtr Foreign.Marshal.Alloc Foreign.Marshal.Array Foreign.Marshal.Utils Foreign.Ptr Foreign.Storable GHC.Stack GHC.Types Numeric Numeric.FormatFloat Numeric.Natural Prelude System.Cmd System.Compress System.Directory System.Environment System.Exit System.IO System.IO.MD5 System.IO.PrintOrRun System.IO.Serialize System.IO.TimeMilli System.IO.Unsafe System.Info System.Process Text.Printf Text.ParserCombinators.ReadP Text.ParserCombinators.ReadPrec Text.Read Text.Read.Lex Text.Show TimeCompat Unsafe.Coerce

$(MCABALBIN)/mhs: bin/mhs
@mkdir -p $(MCABALBIN)
Expand Down
2 changes: 2 additions & 0 deletions lib/AllOfLib.hs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import Data.Eq
import Data.FloatW
import Data.Floating
import Data.Foldable
import Data.Foldable1
import Data.Fractional
import Data.Function
import Data.Functor
Expand All @@ -51,6 +52,7 @@ import Data.List_Type
import Data.Maybe
import Data.Maybe_Type
import Data.Monoid
import Data.Monoid.Internal
import Data.Num
import Data.Ord
import Data.Orphans
Expand Down
2 changes: 1 addition & 1 deletion lib/Control/Monad.hs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import Data.Char_Type
import Data.Function
import Data.Functor
import Data.List
import Data.Monoid
import Data.Monoid.Internal
import Data.Ord
--import Data.Maybe

Expand Down
2 changes: 1 addition & 1 deletion lib/Control/Monad/Fix.hs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module Control.Monad.Fix(
import Control.Monad
import Data.Function(fix)
import Data.List.NonEmpty(NonEmpty(..))
import Data.Monoid
import Data.Monoid.Internal
import Data.Tuple

class (Monad m) => MonadFix m where
Expand Down
13 changes: 1 addition & 12 deletions lib/Control/Monad/Zip.hs
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,9 @@
-----------------------------------------------------------------------------

module Control.Monad.Zip where
{-
import GHC.Internal.Control.Monad (liftM, liftM2)
import GHC.Internal.Data.Functor.Identity
import qualified GHC.Internal.Data.Functor
import GHC.Internal.Data.Monoid
import GHC.Internal.Data.Ord ( Down(..) )
import GHC.Internal.Data.Proxy
import GHC.Generics
import GHC.Tuple (Solo (..))
import Prelude
-}
import Control.Monad
import Data.Functor.Identity
import Data.Monoid
import Data.Monoid.Internal
import qualified Data.List.NonEmpty as NE
--import Data.Tuple

Expand Down
2 changes: 1 addition & 1 deletion lib/Data/ByteString.hs
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ import qualified Prelude as P
import qualified Data.List as P
import Data.List.NonEmpty(NonEmpty, fromList)
import Data.Bits
import Data.Monoid
import Data.Monoid.Internal
import Data.Semigroup
import Data.String
import Data.Word(Word8)
Expand Down
2 changes: 1 addition & 1 deletion lib/Data/Foldable.hs
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@ import Data.List_Type hiding (concatMap)
import qualified Data.List as List
import Data.Maybe
import Data.Monoid
import Data.Monoid.Internal
import Data.Num
import Data.Ord
import Data.Proxy
import Data.Semigroup

newtype MMax a = MMax (Maybe a)
getMMax :: forall a . MMax a -> Maybe a
Expand Down
2 changes: 1 addition & 1 deletion lib/Data/Functor/Compose.hs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import Control.Applicative
import Data.Data (Data)
import Data.Foldable (Foldable(..))
import Data.Functor.Classes
import Data.Monoid
import Data.Monoid.Internal
import Data.Traversable
--import Data.Type.Equality (TestEquality(..), (:~:)(..))
--import GHC.Generics (Generic, Generic1)
Expand Down
2 changes: 1 addition & 1 deletion lib/Data/Functor/Const.hs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import Data.Function
import Data.Functor
import Data.Functor.Const_Type
import Data.Int
import Data.Monoid
import Data.Monoid.Internal
import Data.Ord
import Text.Show

Expand Down
3 changes: 1 addition & 2 deletions lib/Data/List.hs
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,9 @@ import Data.Int
import Data.Integral
import Data.List_Type
import Data.Maybe_Type
import Data.Monoid
import Data.Monoid.Internal
import Data.Num
import Data.Ord
import Data.Semigroup
import Data.Tuple
--import Text.Read
import Text.Show
Expand Down
2 changes: 1 addition & 1 deletion lib/Data/List/NonEmpty.hs
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ import Data.List_Type
import Data.List.NonEmpty_Type
import Data.Num
import Data.Maybe
import Data.Monoid
import Data.Monoid.Internal
import Data.Ord
import Data.Traversable
import Data.Tuple
Expand Down
3 changes: 1 addition & 2 deletions lib/Data/Maybe.hs
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@ import Data.Functor
import Data.Int
import Data.List
import Data.Maybe_Type
import Data.Monoid
import Data.Monoid.Internal
import Data.Ord
import Data.Semigroup
import Text.Show

instance forall a . Eq a => Eq (Maybe a) where
Expand Down
Loading

0 comments on commit e310260

Please sign in to comment.