[Git][ghc/ghc][wip/spj-reinstallable-base2] 2 commits: orphans missing from essentials
Rodrigo Mesquita pushed to branch wip/spj-reinstallable-base2 at Glasgow Haskell Compiler / GHC Commits: 9a1fb983 by Rodrigo Mesquita at 2026-05-13T15:45:40+01:00 orphans missing from essentials - - - - - baf37fe7 by Rodrigo Mesquita at 2026-05-13T17:25:45+01:00 Everything in ghc-internal which needs to construct callstack needs imports - - - - - 14 changed files: - libraries/base/src/GHC/Essentials.hs - libraries/ghc-internal/src/GHC/Internal/Bits.hs - libraries/ghc-internal/src/GHC/Internal/Char.hs - libraries/ghc-internal/src/GHC/Internal/Control/Monad/Fail.hs - libraries/ghc-internal/src/GHC/Internal/Data/Maybe.hs - libraries/ghc-internal/src/GHC/Internal/Float.hs - libraries/ghc-internal/src/GHC/Internal/IO.hs-boot - libraries/ghc-internal/src/GHC/Internal/List.hs - libraries/ghc-internal/src/GHC/Internal/Records.hs - libraries/ghc-internal/src/GHC/Internal/Stack.hs-boot - libraries/ghc-internal/src/GHC/Internal/Stack/Constants.hsc - libraries/ghc-internal/src/GHC/Internal/Stack/ConstantsProf.hsc - libraries/ghc-internal/src/GHC/Internal/Text/ParserCombinators/ReadPrec.hs - libraries/ghc-internal/src/GHC/Internal/Unsafe/Coerce.hs Changes: ===================================== libraries/base/src/GHC/Essentials.hs ===================================== @@ -24,7 +24,8 @@ module GHC.Essentials -- Misc , (.), (&&), not, foldrList, build, map - , seq# + , seq#, ($), assert, considerAccessible + , augment, otherwise, -- Applicative , Applicative, pure, mzip, (<*>), (*>), liftA2 ===================================== libraries/ghc-internal/src/GHC/Internal/Bits.hs ===================================== @@ -73,6 +73,7 @@ import GHC.Internal.Prim ( (-#), (==#), (>=#) ) import GHC.Internal.Real +import GHC.Internal.Stack.Types infixl 8 `shift`, `rotate`, `shiftL`, `shiftR`, `rotateL`, `rotateR` infixl 7 .&. ===================================== libraries/ghc-internal/src/GHC/Internal/Char.hs ===================================== @@ -11,6 +11,7 @@ module GHC.Internal.Char ) where import GHC.Internal.Base +import GHC.Internal.Stack.Types import GHC.Internal.Err (error) import GHC.Internal.Show import GHC.Internal.Prim (chr#, int2Word#, leWord#, Int#, Char#) ===================================== libraries/ghc-internal/src/GHC/Internal/Control/Monad/Fail.hs ===================================== @@ -21,7 +21,7 @@ import GHC.Internal.Base import {-# SOURCE #-} GHC.Internal.IO (throwIO) import {-# SOURCE #-} GHC.Internal.IO.Exception (userError) import GHC.Internal.Maybe (Maybe(..)) -import GHC.Internal.Stack.Types (HasCallStack) +import GHC.Internal.Stack.Types -- | When a value is bound in @do@-notation, the pattern on the left -- hand side of @<-@ might not match. In this case, this class ===================================== libraries/ghc-internal/src/GHC/Internal/Data/Maybe.hs ===================================== @@ -34,7 +34,7 @@ module GHC.Internal.Data.Maybe import GHC.Internal.Base import GHC.Internal.Err (error) import GHC.Internal.Maybe (Maybe(..)) -import GHC.Internal.Stack.Types (HasCallStack) +import GHC.Internal.Stack.Types -- $setup -- Allow the use of some Prelude functions in doctests. ===================================== libraries/ghc-internal/src/GHC/Internal/Float.hs ===================================== @@ -203,6 +203,7 @@ import GHC.Internal.Arr import GHC.Internal.Float.RealFracMethods import GHC.Internal.Float.ConversionUtils import GHC.Internal.Bignum.BigNat +import GHC.Internal.Stack.Types as Rebindable #if WORD_SIZE_IN_BITS == 64 import GHC.Internal.Prim ( ===================================== libraries/ghc-internal/src/GHC/Internal/IO.hs-boot ===================================== @@ -1,9 +1,10 @@ {-# LANGUAGE Unsafe #-} {-# LANGUAGE NoImplicitPrelude #-} +{-# OPTIONS_GHC -fdefines-known-key-names #-} module GHC.Internal.IO where -import GHC.Internal.Stack.Types (HasCallStack) +import GHC.Internal.Stack.Types import GHC.Internal.Types import {-# SOURCE #-} GHC.Internal.Exception.Type (Exception, SomeException) ===================================== libraries/ghc-internal/src/GHC/Internal/List.hs ===================================== @@ -49,7 +49,7 @@ import GHC.Internal.Err (error) import GHC.Internal.Num (Num(..)) import GHC.Internal.Bignum.Integer (Integer) import GHC.Internal.Prim (seq) -import GHC.Internal.Stack.Types (HasCallStack) +import GHC.Internal.Stack.Types infixl 9 !?, !! infix 4 `elem`, `notElem` ===================================== libraries/ghc-internal/src/GHC/Internal/Records.hs ===================================== @@ -32,6 +32,7 @@ module GHC.Internal.Records import GHC.Internal.Base import GHC.Internal.Err( error ) +import GHC.Internal.Stack.Types -- | Constraint representing the fact that the field @x@ belongs to -- the record type @r@ and has field type @a@. This will be solved ===================================== libraries/ghc-internal/src/GHC/Internal/Stack.hs-boot ===================================== @@ -1,9 +1,9 @@ -{-# LANGUAGE NoImplicitPrelude, RankNTypes #-} +{-# LANGUAGE NoImplicitPrelude, RankNTypes, MagicHash #-} module GHC.Internal.Stack where -import GHC.Internal.Base (String) -import GHC.Internal.Stack.Types (HasCallStack, CallStack, SrcLoc) +import GHC.Internal.Base +import GHC.Internal.Stack.Types prettyCallStackLines :: CallStack -> [String] prettyCallStack :: CallStack -> String ===================================== libraries/ghc-internal/src/GHC/Internal/Stack/Constants.hsc ===================================== @@ -9,6 +9,7 @@ import GHC.Internal.Err (error) import GHC.Internal.Num import GHC.Internal.Show import GHC.Internal.Real +import GHC.Internal.Stack.Types #include "Rts.h" #undef BLOCK_SIZE ===================================== libraries/ghc-internal/src/GHC/Internal/Stack/ConstantsProf.hsc ===================================== @@ -8,6 +8,7 @@ import GHC.Internal.Enum import GHC.Internal.Err (error) import GHC.Internal.Num import GHC.Internal.Show +import GHC.Internal.Stack.Types import GHC.Internal.Real -- This file is a copy of GHC.Internal.Stack.Constants, but compiled with PROFILING ===================================== libraries/ghc-internal/src/GHC/Internal/Text/ParserCombinators/ReadPrec.hs ===================================== @@ -64,6 +64,7 @@ import qualified GHC.Internal.Text.ParserCombinators.ReadP as ReadP import GHC.Internal.Base import GHC.Internal.Num( Num(..) ) import GHC.Internal.Control.Monad.Fail +import GHC.Internal.Stack.Types as Rebindable -- --------------------------------------------------------------------------- -- The readPrec type ===================================== libraries/ghc-internal/src/GHC/Internal/Unsafe/Coerce.hs ===================================== @@ -25,6 +25,7 @@ module GHC.Internal.Unsafe.Coerce import GHC.Internal.Base import GHC.Internal.Arr (amap) -- For amap/unsafeCoerce rule import GHC.Internal.Err (error) +import GHC.Internal.Stack.Types as Rebindable {- Note [Implementing unsafeCoerce] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/a0f4834ce0c1fa6b1b7c75776b78cdf... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/a0f4834ce0c1fa6b1b7c75776b78cdf... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Rodrigo Mesquita (@alt-romes)