Teo Camarasu pushed to branch wip/T26832 at Glasgow Haskell Compiler / GHC

Commits:

27 changed files:

Changes:

  • .gitlab-ci.yml
    ... ... @@ -1050,10 +1050,6 @@ abi-test:
    1050 1050
           optional: true
    
    1051 1051
       dependencies: null
    
    1052 1052
       image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-fedora43:$DOCKER_REV"
    
    1053
    -  rules:
    
    1054
    -    - if: $CI_MERGE_REQUEST_ID
    
    1055
    -    - if: '$CI_COMMIT_BRANCH == "master"'
    
    1056
    -    - if: '$CI_COMMIT_BRANCH =~ /ghc-[0.9]+\.[0-9]+/'
    
    1057 1053
       tags:
    
    1058 1054
         - x86_64-linux
    
    1059 1055
       script:
    

  • .gitlab/ci.sh
    ... ... @@ -493,6 +493,11 @@ function fetch_perf_notes() {
    493 493
     }
    
    494 494
     
    
    495 495
     function push_perf_notes() {
    
    496
    +  if [[ "${CI_COMMIT_BRANCH:-}" != "master" ]] && [[ ! "${CI_COMMIT_BRANCH:-}" =~ ghc-[0-9]+\.[0-9]+ ]]; then
    
    497
    +    info "Perf notes are only pushed on master/release branches"
    
    498
    +    return
    
    499
    +  fi
    
    500
    +
    
    496 501
       if [[ -z "${TEST_ENV:-}" ]]; then
    
    497 502
         return
    
    498 503
       fi
    

  • compiler/GHC/Builtin/Names.hs
    ... ... @@ -1063,7 +1063,7 @@ alternativeClassKey = mkPreludeMiscIdUnique 754
    1063 1063
     
    
    1064 1064
     -- Functions for GHC extensions
    
    1065 1065
     considerAccessibleName :: Name
    
    1066
    -considerAccessibleName = varQual gHC_INTERNAL_EXTS (fsLit "considerAccessible") considerAccessibleIdKey
    
    1066
    +considerAccessibleName = varQual gHC_MAGIC (fsLit "considerAccessible") considerAccessibleIdKey
    
    1067 1067
     
    
    1068 1068
     -- Random GHC.Internal.Base functions
    
    1069 1069
     fromStringName, otherwiseIdName, foldrName, buildName, augmentName,
    

  • docs/users_guide/exts/roles.rst
    ... ... @@ -38,7 +38,7 @@ trouble.
    38 38
     The way to identify such situations is to have *roles* assigned to type
    
    39 39
     variables of datatypes, classes, and type synonyms.
    
    40 40
     
    
    41
    -Roles as implemented in GHC are a from a simplified version of the work
    
    41
    +Roles as implemented in GHC are based on a simplified version of the work
    
    42 42
     described in `Generative type abstraction and type-level
    
    43 43
     computation <https://www.seas.upenn.edu/~sweirich/papers/popl163af-weirich.pdf>`__,
    
    44 44
     published at POPL 2011.
    

  • hadrian/src/Context.hs
    ... ... @@ -11,7 +11,7 @@ module Context (
    11 11
         pkgLibraryFile,
    
    12 12
         pkgConfFile, pkgStampFile, resourcePath, objectPath, contextPath, getContextPath, libPath, distDir,
    
    13 13
         distDynDir,
    
    14
    -    haddockStatsFilesDir, ensureConfigured, autogenPath, rtsContext, rtsBuildPath, libffiBuildPath
    
    14
    +    haddockStatsFilesDir, ensureConfigured, autogenPath, rtsContext, rtsBuildPath
    
    15 15
         ) where
    
    16 16
     
    
    17 17
     import Base
    
    ... ... @@ -93,14 +93,6 @@ rtsContext stage = vanillaContext stage rts
    93 93
     rtsBuildPath :: Stage -> Action FilePath
    
    94 94
     rtsBuildPath stage = buildPath (rtsContext stage)
    
    95 95
     
    
    96
    --- | Build directory for in-tree 'libffi' library.
    
    97
    -libffiBuildPath :: Stage -> Action FilePath
    
    98
    -libffiBuildPath stage = buildPath $ Context
    
    99
    -    stage
    
    100
    -    libffi
    
    101
    -    (error "libffiBuildPath: way not set.")
    
    102
    -    (error "libffiBuildPath: inplace not set.")
    
    103
    -
    
    104 96
     pkgFileName :: Context -> Package -> String -> String -> Action FilePath
    
    105 97
     pkgFileName context package prefix suffix = do
    
    106 98
         pid  <- pkgUnitId (stage context) package
    

  • hadrian/src/Settings/Builders/Configure.hs
    ... ... @@ -8,8 +8,7 @@ configureBuilderArgs :: Args
    8 8
     configureBuilderArgs = do
    
    9 9
         stage      <- getStage
    
    10 10
         gmpPath    <- expr (gmpBuildPath stage)
    
    11
    -    libffiPath <- expr (libffiBuildPath stage)
    
    12
    -    mconcat [ builder (Configure gmpPath) ? do
    
    11
    +    builder (Configure gmpPath) ? do
    
    13 12
                     targetArch <- queryTarget queryArch
    
    14 13
                     targetPlatform <- queryTarget targetPlatformTriple
    
    15 14
                     buildPlatform <- queryBuild targetPlatformTriple
    
    ... ... @@ -28,16 +27,3 @@ configureBuilderArgs = do
    28 27
                          -- option.
    
    29 28
                          <> [ "--enable-alloca=malloc-notreentrant" | targetArch == "wasm32" ]
    
    30 29
                          <> [ "--with-pic=yes" ]
    31
    -
    
    32
    -            , builder (Configure libffiPath) ? do
    
    33
    -                top            <- expr topDirectory
    
    34
    -                targetPlatform <- queryTarget targetPlatformTriple
    
    35
    -                way            <- getWay
    
    36
    -                pure [ "--prefix=" ++ top -/- libffiPath -/- "inst"
    
    37
    -                     , "--libdir=" ++ top -/- libffiPath -/- "inst/lib"
    
    38
    -                     , "--enable-static=yes"
    
    39
    -                     , "--enable-shared="
    
    40
    -                            ++ (if wayUnit Dynamic way
    
    41
    -                                    then "yes"
    
    42
    -                                    else "no")
    
    43
    -                     , "--host=" ++ targetPlatform ] ]

  • hadrian/src/Settings/Builders/Make.hs
    ... ... @@ -12,12 +12,8 @@ makeBuilderArgs = do
    12 12
         threads    <- shakeThreads <$> expr getShakeOptions
    
    13 13
         stage      <- getStage
    
    14 14
         gmpPath    <- expr (gmpBuildPath stage)
    
    15
    -    libffiPaths <- forM [Stage1, Stage2, Stage3 ] $ \s -> expr (libffiBuildPath s)
    
    16 15
         let t = show $ max 4 (threads - 2) -- Don't use all Shake's threads
    
    17
    -    mconcat $
    
    18
    -        (builder (Make gmpPath   ) ? pure ["MAKEFLAGS=-j" ++ t]) :
    
    19
    -        [ builder (Make libffiPath) ? pure ["MAKEFLAGS=-j" ++ t, "install"]
    
    20
    -        | libffiPath <- libffiPaths ]
    
    16
    +    builder (Make gmpPath) ? pure ["MAKEFLAGS=-j" ++ t]
    
    21 17
     
    
    22 18
     validateBuilderArgs :: Args
    
    23 19
     validateBuilderArgs = builder (Make "testsuite/tests") ? do
    

  • libraries/base/changelog.md
    ... ... @@ -22,6 +22,7 @@
    22 22
       * `GHC.Conc.throwSTM` and `GHC.Conc.Sync.throwSTM` now carry a `HasCallStack` constraint and attach a `Backtrace` annotation to the thrown exception. ([GHC #25365](https://gitlab.haskell.org/ghc/ghc/-/issues/25365))
    
    23 23
       * `GHC.Conc.catchSTM` and `GHC.Conc.Sync.catchSTM` now attach `WhileHandling` annotation to exceptions thrown from the handler. ([GHC #25365](https://gitlab.haskell.org/ghc/ghc/-/issues/25365))
    
    24 24
       * Remove `GHC.JS.Prim.Internal.Build`, as per [CLC #329](https://github.com/haskell/core-libraries-committee/issues/329)
    
    25
    +  * Export `labelThread` from `Control.Concurrent`.([CLC proposal #376](https://github.com/haskell/core-libraries-committee/issues/376))
    
    25 26
     
    
    26 27
     ## 4.22.0.0 *TBA*
    
    27 28
       * Shipped with GHC 9.14.1
    

  • libraries/base/src/Control/Concurrent.hs
    ... ... @@ -82,6 +82,9 @@ module Control.Concurrent (
    82 82
             -- * Weak references to ThreadIds
    
    83 83
             mkWeakThreadId,
    
    84 84
     
    
    85
    +        -- * Thread debugging
    
    86
    +        labelThread,
    
    87
    +
    
    85 88
             -- * GHC's implementation of concurrency
    
    86 89
     
    
    87 90
             -- |This section describes features specific to GHC's
    

  • libraries/base/src/System/Timeout.hs
    ... ... @@ -29,7 +29,6 @@ import GHC.Internal.Control.Exception (Exception(..), handleJust, bracket,
    29 29
                                 asyncExceptionToException,
    
    30 30
                                 asyncExceptionFromException)
    
    31 31
     import GHC.Internal.Data.Unique         (Unique, newUnique)
    
    32
    -import GHC.Conc (labelThread)
    
    33 32
     import Prelude
    
    34 33
     
    
    35 34
     -- $setup
    

  • libraries/ghc-internal/src/GHC/Internal/Exts.hs
    ... ... @@ -321,10 +321,7 @@ import GHC.Internal.Data.Data
    321 321
     import GHC.Internal.Data.Ord
    
    322 322
     import qualified GHC.Internal.Debug.Trace
    
    323 323
     import GHC.Internal.Unsafe.Coerce ( unsafeCoerce# ) -- just for re-export
    
    324
    -
    
    325
    --- XXX This should really be in Data.Tuple, where the definitions are
    
    326
    -maxTupleSize :: Int
    
    327
    -maxTupleSize = 64
    
    324
    +import GHC.Internal.Tuple (maxTupleSize)
    
    328 325
     
    
    329 326
     -- | 'the' ensures that all the elements of the list are identical
    
    330 327
     -- and then returns that unique element
    
    ... ... @@ -444,27 +441,3 @@ resizeSmallMutableArray# arr0 szNew a s0 =
    444 441
               (# s2, arr1 #) -> case copySmallMutableArray# arr0 0# arr1 0# szOld s2 of
    
    445 442
                 s3 -> (# s3, arr1 #)
    
    446 443
             else (# s1, arr0 #)
    447
    -
    
    448
    --- | Semantically, @considerAccessible = True@. But it has special meaning
    
    449
    --- to the pattern-match checker, which will never flag the clause in which
    
    450
    --- 'considerAccessible' occurs as a guard as redundant or inaccessible.
    
    451
    --- Example:
    
    452
    ---
    
    453
    --- > case (x, x) of
    
    454
    --- >   (True,  True)  -> 1
    
    455
    --- >   (False, False) -> 2
    
    456
    --- >   (True,  False) -> 3 -- Warning: redundant
    
    457
    ---
    
    458
    --- The pattern-match checker will warn here that the third clause is redundant.
    
    459
    --- It will stop doing so if the clause is adorned with 'considerAccessible':
    
    460
    ---
    
    461
    --- > case (x, x) of
    
    462
    --- >   (True,  True)  -> 1
    
    463
    --- >   (False, False) -> 2
    
    464
    --- >   (True,  False) | considerAccessible -> 3 -- No warning
    
    465
    ---
    
    466
    --- Put 'considerAccessible' as the last statement of the guard to avoid get
    
    467
    --- confusing results from the pattern-match checker, which takes \"consider
    
    468
    --- accessible\" by word.
    
    469
    -considerAccessible :: Bool
    
    470
    -considerAccessible = True

  • libraries/ghc-internal/src/GHC/Internal/Heap/Closures.hs
    ... ... @@ -75,9 +75,10 @@ import GHC.Internal.Int
    75 75
     import GHC.Internal.Num
    
    76 76
     import GHC.Internal.Real
    
    77 77
     import GHC.Internal.Word
    
    78
    -import GHC.Internal.Exts
    
    79 78
     import GHC.Internal.Generics
    
    80 79
     import GHC.Internal.Numeric
    
    80
    +import GHC.Internal.Ptr
    
    81
    +import GHC.Internal.Unsafe.Coerce
    
    81 82
     import GHC.Internal.Stack (HasCallStack)
    
    82 83
     
    
    83 84
     ------------------------------------------------------------------------
    

  • libraries/ghc-internal/src/GHC/Internal/JS/Foreign/Callback.hs
    ... ... @@ -21,8 +21,6 @@ module GHC.Internal.JS.Foreign.Callback
    21 21
     
    
    22 22
     import           GHC.Internal.JS.Prim
    
    23 23
     
    
    24
    -import qualified GHC.Internal.Exts as Exts
    
    25
    -
    
    26 24
     import           GHC.Internal.Unsafe.Coerce
    
    27 25
     import           GHC.Internal.Base
    
    28 26
     
    
    ... ... @@ -131,18 +129,18 @@ asyncCallback3 x = js_asyncCallbackApply 3 (unsafeCoerce x)
    131 129
     -- ----------------------------------------------------------------------------
    
    132 130
     
    
    133 131
     foreign import javascript unsafe "(($1, $2) => { return h$makeCallback(h$runSync, [$1], $2); })"
    
    134
    -  js_syncCallback :: Bool -> Exts.Any -> IO (Callback (IO b))
    
    132
    +  js_syncCallback :: Bool -> Any -> IO (Callback (IO b))
    
    135 133
     foreign import javascript unsafe "(($1) => { return h$makeCallback(h$run, [], $1); })"
    
    136
    -  js_asyncCallback :: Exts.Any -> IO (Callback (IO b))
    
    134
    +  js_asyncCallback :: Any -> IO (Callback (IO b))
    
    137 135
     foreign import javascript unsafe "(($1) => { return h$makeCallback(h$runSyncReturn, [false], $1); })"
    
    138
    -  js_syncCallbackReturn :: Exts.Any -> IO (Callback (IO JSVal))
    
    136
    +  js_syncCallbackReturn :: Any -> IO (Callback (IO JSVal))
    
    139 137
     
    
    140 138
     foreign import javascript unsafe "(($1, $2, $3) => { return h$makeCallbackApply($2, h$runSync, [$1], $3); })"
    
    141
    -  js_syncCallbackApply :: Bool -> Int -> Exts.Any -> IO (Callback b)
    
    139
    +  js_syncCallbackApply :: Bool -> Int -> Any -> IO (Callback b)
    
    142 140
     foreign import javascript unsafe "(($1, $2) => { return h$makeCallbackApply($1, h$run, [], $2); })"
    
    143
    -  js_asyncCallbackApply :: Int -> Exts.Any -> IO (Callback b)
    
    141
    +  js_asyncCallbackApply :: Int -> Any -> IO (Callback b)
    
    144 142
     foreign import javascript unsafe "(($1, $2) => { return h$makeCallbackApply($1, h$runSyncReturn, [false], $2); })"
    
    145
    -  js_syncCallbackApplyReturn :: Int -> Exts.Any -> IO (Callback b)
    
    143
    +  js_syncCallbackApplyReturn :: Int -> Any -> IO (Callback b)
    
    146 144
     
    
    147 145
     foreign import javascript unsafe "h$release"
    
    148 146
       js_release :: Callback a -> IO ()

  • libraries/ghc-internal/src/GHC/Internal/JS/Prim.hs
    ... ... @@ -42,8 +42,8 @@ module GHC.Internal.JS.Prim ( JSVal(..), JSVal#
    42 42
     import           GHC.Internal.Unsafe.Coerce (unsafeCoerce)
    
    43 43
     
    
    44 44
     import           GHC.Internal.Prim
    
    45
    +import           GHC.Internal.Types
    
    45 46
     import qualified GHC.Internal.Exception as Ex
    
    46
    -import qualified GHC.Internal.Exts as Exts
    
    47 47
     import qualified GHC.Internal.CString as GHC
    
    48 48
     import           GHC.Internal.IO
    
    49 49
     import           GHC.Internal.Data.Bool
    
    ... ... @@ -78,15 +78,15 @@ instance Show JSException where
    78 78
     #if defined(javascript_HOST_ARCH)
    
    79 79
     
    
    80 80
     {-# NOINLINE toIO #-}
    
    81
    -toIO :: Exts.Any -> IO Exts.Any
    
    81
    +toIO :: Any -> IO Any
    
    82 82
     toIO x = pure x
    
    83 83
     
    
    84 84
     {-# NOINLINE resolve #-}
    
    85
    -resolve :: JSVal# -> JSVal# -> Exts.Any -> IO ()
    
    85
    +resolve :: JSVal# -> JSVal# -> Any -> IO ()
    
    86 86
     resolve accept reject x = resolveIO accept reject (pure x)
    
    87 87
     
    
    88 88
     {-# NOINLINE resolveIO #-} -- used by the rts
    
    89
    -resolveIO :: JSVal# -> JSVal# -> IO Exts.Any -> IO ()
    
    89
    +resolveIO :: JSVal# -> JSVal# -> IO Any -> IO ()
    
    90 90
     resolveIO accept reject x =
    
    91 91
       (x >>= evaluate >>= js_callback_any accept) `catch`
    
    92 92
       (\(e::Ex.SomeException) -> do
    
    ... ... @@ -260,16 +260,16 @@ seqList xs = go xs `seq` xs
    260 260
             go []     = ()
    
    261 261
     
    
    262 262
     foreign import javascript unsafe "h$toHsString"
    
    263
    -  js_fromJSString :: JSVal -> Exts.Any
    
    263
    +  js_fromJSString :: JSVal -> Any
    
    264 264
     
    
    265 265
     foreign import javascript unsafe "h$fromHsString"
    
    266
    -  js_toJSString :: Exts.Any -> JSVal
    
    266
    +  js_toJSString :: Any -> JSVal
    
    267 267
     
    
    268 268
     foreign import javascript unsafe "h$toHsListJSVal"
    
    269
    -  js_fromJSArray :: JSVal -> IO Exts.Any
    
    269
    +  js_fromJSArray :: JSVal -> IO Any
    
    270 270
     
    
    271 271
     foreign import javascript unsafe "h$fromHsListJSVal"
    
    272
    -  js_toJSArray :: Exts.Any -> IO JSVal
    
    272
    +  js_toJSArray :: Any -> IO JSVal
    
    273 273
     
    
    274 274
     foreign import javascript unsafe "(($1) => { return ($1 === null); })"
    
    275 275
       js_isNull :: JSVal -> Bool
    
    ... ... @@ -287,10 +287,10 @@ foreign import javascript unsafe "(() => { return null; })"
    287 287
       js_null :: JSVal
    
    288 288
     
    
    289 289
     foreign import javascript unsafe "(($1,$2) => { return $1[h$fromHsString($2)]; })"
    
    290
    -  js_getProp :: JSVal -> Exts.Any -> IO JSVal
    
    290
    +  js_getProp :: JSVal -> Any -> IO JSVal
    
    291 291
     
    
    292 292
     foreign import javascript unsafe "(($1,$2) => { return $1[h$fromHsString($2)]; })"
    
    293
    -  js_unsafeGetProp :: JSVal -> Exts.Any -> JSVal
    
    293
    +  js_unsafeGetProp :: JSVal -> Any -> JSVal
    
    294 294
     
    
    295 295
     foreign import javascript unsafe "(($1,$2) => { return $1[$2]; })"
    
    296 296
       js_getProp' :: JSVal -> JSVal -> IO JSVal
    
    ... ... @@ -311,7 +311,7 @@ foreign import javascript unsafe "(($1_1, $1_2) => { return h$decodeUtf8z($1_1,$
    311 311
       js_unsafeUnpackJSStringUtf8## :: Addr# -> JSVal#
    
    312 312
     
    
    313 313
     foreign import javascript unsafe "(($1, $2) => { return $1($2); })"
    
    314
    -  js_callback_any :: JSVal# -> Exts.Any -> IO ()
    
    314
    +  js_callback_any :: JSVal# -> Any -> IO ()
    
    315 315
     
    
    316 316
     foreign import javascript unsafe "(($1, $2) => { return $1($2); })"
    
    317 317
       js_callback_jsval :: JSVal# -> JSVal -> IO ()
    

  • libraries/ghc-internal/src/GHC/Internal/JS/Prim/Internal/Build.hs
    ... ... @@ -145,7 +145,6 @@ module GHC.Internal.JS.Prim.Internal.Build
    145 145
       ) where
    
    146 146
     
    
    147 147
     import GHC.Internal.JS.Prim
    
    148
    -import GHC.Internal.Exts
    
    149 148
     import GHC.Internal.IO
    
    150 149
     import GHC.Internal.Unsafe.Coerce
    
    151 150
     import GHC.Internal.Base
    

  • libraries/ghc-internal/src/GHC/Internal/Magic.hs
    ... ... @@ -24,7 +24,7 @@
    24 24
     --
    
    25 25
     -----------------------------------------------------------------------------
    
    26 26
     
    
    27
    -module GHC.Internal.Magic ( inline, noinline, lazy, oneShot, runRW#, DataToTag(..) ) where
    
    27
    +module GHC.Internal.Magic ( inline, noinline, lazy, oneShot, runRW#, DataToTag(..), considerAccessible ) where
    
    28 28
     
    
    29 29
     --------------------------------------------------
    
    30 30
     --        See Note [magicIds] in GHC.Types.Id.Make
    
    ... ... @@ -34,7 +34,7 @@ module GHC.Internal.Magic ( inline, noinline, lazy, oneShot, runRW#, DataToTag(.
    34 34
     -- because TYPE is not exported by the source Haskell module generated by
    
    35 35
     -- genprimops which Haddock will typecheck (#15935).
    
    36 36
     import GHC.Internal.Prim (State#, realWorld#, RealWorld, Int#)
    
    37
    -import GHC.Internal.Types (RuntimeRep(BoxedRep), TYPE, Levity, Constraint)
    
    37
    +import GHC.Internal.Types (RuntimeRep(BoxedRep), TYPE, Levity, Constraint, Bool(True))
    
    38 38
     
    
    39 39
     -- | The call @inline f@ arranges that @f@ is inlined, regardless of
    
    40 40
     -- its size. More precisely, the call @inline f@ rewrites to the
    
    ... ... @@ -137,3 +137,27 @@ type DataToTag :: forall {lev :: Levity}. TYPE (BoxedRep lev) -> Constraint
    137 137
     -- So it does not get its own Unsafe module, unlike WithDict.
    
    138 138
     class DataToTag a where
    
    139 139
       dataToTag# :: a -> Int#
    
    140
    +
    
    141
    +-- | Semantically, @considerAccessible = True@. But it has special meaning
    
    142
    +-- to the pattern-match checker, which will never flag the clause in which
    
    143
    +-- 'considerAccessible' occurs as a guard as redundant or inaccessible.
    
    144
    +-- Example:
    
    145
    +--
    
    146
    +-- > case (x, x) of
    
    147
    +-- >   (True,  True)  -> 1
    
    148
    +-- >   (False, False) -> 2
    
    149
    +-- >   (True,  False) -> 3 -- Warning: redundant
    
    150
    +--
    
    151
    +-- The pattern-match checker will warn here that the third clause is redundant.
    
    152
    +-- It will stop doing so if the clause is adorned with 'considerAccessible':
    
    153
    +--
    
    154
    +-- > case (x, x) of
    
    155
    +-- >   (True,  True)  -> 1
    
    156
    +-- >   (False, False) -> 2
    
    157
    +-- >   (True,  False) | considerAccessible -> 3 -- No warning
    
    158
    +--
    
    159
    +-- Put 'considerAccessible' as the last statement of the guard to avoid get
    
    160
    +-- confusing results from the pattern-match checker, which takes \"consider
    
    161
    +-- accessible\" by word.
    
    162
    +considerAccessible :: Bool
    
    163
    +considerAccessible = True

  • libraries/ghc-internal/src/GHC/Internal/Stack/Decode.hs
    ... ... @@ -40,8 +40,8 @@ import GHC.Internal.Data.List
    40 40
     import GHC.Internal.Data.Tuple
    
    41 41
     import GHC.Internal.Foreign.Ptr
    
    42 42
     import GHC.Internal.Foreign.Storable
    
    43
    -import GHC.Internal.Exts
    
    44 43
     import GHC.Internal.Unsafe.Coerce
    
    44
    +import GHC.Internal.Ptr
    
    45 45
     
    
    46 46
     import GHC.Internal.ClosureTypes
    
    47 47
     import GHC.Internal.Heap.Closures
    

  • libraries/ghc-internal/src/GHC/Internal/Tuple.hs
    ... ... @@ -27,10 +27,11 @@ module GHC.Internal.Tuple (
    27 27
       Tuple40(..), Tuple41(..), Tuple42(..), Tuple43(..), Tuple44(..), Tuple45(..), Tuple46(..), Tuple47(..), Tuple48(..), Tuple49(..),
    
    28 28
       Tuple50(..), Tuple51(..), Tuple52(..), Tuple53(..), Tuple54(..), Tuple55(..), Tuple56(..), Tuple57(..), Tuple58(..), Tuple59(..),
    
    29 29
       Tuple60(..), Tuple61(..), Tuple62(..), Tuple63(..), Tuple64(..),
    
    30
    +  maxTupleSize,
    
    30 31
     ) where
    
    31 32
     
    
    32 33
     -- See W1 of Note [Tracking dependencies on primitives] in GHC.Internal.Base
    
    33
    -import GHC.Internal.Types ()
    
    34
    +import GHC.Internal.Types (Int)
    
    34 35
     
    
    35 36
     default () -- Double and Integer aren't available yet
    
    36 37
     
    
    ... ... @@ -598,3 +599,6 @@ data Tuple64 a b c d e f g h i j k l m n o p q r s t u v w x y z a1 b1 c1 d1 e1
    598 599
           r1 s1 t1 u1 v1 w1 x1 y1 z1 a2 b2 c2 d2 e2 f2 g2 h2 i2 j2 k2 l2
    
    599 600
       = (a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,a1,b1,c1,d1,e1,f1,g1,h1,i1,j1,k1,l1,m1,n1,o1,p1,q1,
    
    600 601
          r1,s1,t1,u1,v1,w1,x1,y1,z1,a2,b2,c2,d2,e2,f2,g2,h2,i2,j2,k2,l2)
    
    602
    +
    
    603
    +maxTupleSize :: Int
    
    604
    +maxTupleSize = 64

  • libraries/ghc-internal/src/GHC/Internal/Wasm/Prim/Exports.hs
    ... ... @@ -32,7 +32,6 @@ module GHC.Internal.Wasm.Prim.Exports (
    32 32
     
    
    33 33
     import GHC.Internal.Base
    
    34 34
     import GHC.Internal.Exception.Type
    
    35
    -import GHC.Internal.Exts
    
    36 35
     import GHC.Internal.IO
    
    37 36
     import GHC.Internal.IORef
    
    38 37
     import GHC.Internal.Int
    

  • libraries/ghc-internal/src/GHC/Internal/Wasm/Prim/Imports.hs
    ... ... @@ -30,7 +30,6 @@ module GHC.Internal.Wasm.Prim.Imports (
    30 30
     
    
    31 31
     import GHC.Internal.Base
    
    32 32
     import GHC.Internal.Exception
    
    33
    -import GHC.Internal.Exts
    
    34 33
     import GHC.Internal.IO.Unsafe
    
    35 34
     import GHC.Internal.Stable
    
    36 35
     import GHC.Internal.Wasm.Prim.Types
    

  • libraries/ghc-internal/src/GHC/Internal/Wasm/Prim/Types.hs
    ... ... @@ -20,7 +20,6 @@ module GHC.Internal.Wasm.Prim.Types (
    20 20
     
    
    21 21
     import GHC.Internal.Base
    
    22 22
     import GHC.Internal.Exception.Type
    
    23
    -import GHC.Internal.Exts
    
    24 23
     import GHC.Internal.Foreign.C.String.Encoding
    
    25 24
     import GHC.Internal.ForeignPtr
    
    26 25
     import GHC.Internal.IO
    

  • testsuite/tests/interface-stability/base-exports.stdout
    ... ... @@ -120,6 +120,7 @@ module Control.Concurrent where
    120 120
       isCurrentThreadBound :: GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    121 121
       isEmptyMVar :: forall a. MVar a -> GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    122 122
       killThread :: ThreadId -> GHC.Internal.Types.IO ()
    
    123
    +  labelThread :: ThreadId -> GHC.Internal.Base.String -> GHC.Internal.Types.IO ()
    
    123 124
       mkWeakMVar :: forall a. MVar a -> GHC.Internal.Types.IO () -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak (MVar a))
    
    124 125
       mkWeakThreadId :: ThreadId -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak ThreadId)
    
    125 126
       modifyMVar :: forall a b. MVar a -> (a -> GHC.Internal.Types.IO (a, b)) -> GHC.Internal.Types.IO b
    

  • testsuite/tests/interface-stability/base-exports.stdout-javascript-unknown-ghcjs
    ... ... @@ -120,6 +120,7 @@ module Control.Concurrent where
    120 120
       isCurrentThreadBound :: GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    121 121
       isEmptyMVar :: forall a. MVar a -> GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    122 122
       killThread :: ThreadId -> GHC.Internal.Types.IO ()
    
    123
    +  labelThread :: ThreadId -> GHC.Internal.Base.String -> GHC.Internal.Types.IO ()
    
    123 124
       mkWeakMVar :: forall a. MVar a -> GHC.Internal.Types.IO () -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak (MVar a))
    
    124 125
       mkWeakThreadId :: ThreadId -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak ThreadId)
    
    125 126
       modifyMVar :: forall a b. MVar a -> (a -> GHC.Internal.Types.IO (a, b)) -> GHC.Internal.Types.IO b
    

  • testsuite/tests/interface-stability/base-exports.stdout-mingw32
    ... ... @@ -120,6 +120,7 @@ module Control.Concurrent where
    120 120
       isCurrentThreadBound :: GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    121 121
       isEmptyMVar :: forall a. MVar a -> GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    122 122
       killThread :: ThreadId -> GHC.Internal.Types.IO ()
    
    123
    +  labelThread :: ThreadId -> GHC.Internal.Base.String -> GHC.Internal.Types.IO ()
    
    123 124
       mkWeakMVar :: forall a. MVar a -> GHC.Internal.Types.IO () -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak (MVar a))
    
    124 125
       mkWeakThreadId :: ThreadId -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak ThreadId)
    
    125 126
       modifyMVar :: forall a b. MVar a -> (a -> GHC.Internal.Types.IO (a, b)) -> GHC.Internal.Types.IO b
    

  • testsuite/tests/interface-stability/base-exports.stdout-ws-32
    ... ... @@ -120,6 +120,7 @@ module Control.Concurrent where
    120 120
       isCurrentThreadBound :: GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    121 121
       isEmptyMVar :: forall a. MVar a -> GHC.Internal.Types.IO GHC.Internal.Types.Bool
    
    122 122
       killThread :: ThreadId -> GHC.Internal.Types.IO ()
    
    123
    +  labelThread :: ThreadId -> GHC.Internal.Base.String -> GHC.Internal.Types.IO ()
    
    123 124
       mkWeakMVar :: forall a. MVar a -> GHC.Internal.Types.IO () -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak (MVar a))
    
    124 125
       mkWeakThreadId :: ThreadId -> GHC.Internal.Types.IO (GHC.Internal.Weak.Weak ThreadId)
    
    125 126
       modifyMVar :: forall a b. MVar a -> (a -> GHC.Internal.Types.IO (a, b)) -> GHC.Internal.Types.IO b
    

  • testsuite/tests/interface-stability/ghc-experimental-exports.stdout
    ... ... @@ -4453,6 +4453,7 @@ module Data.Tuple.Experimental where
    4453 4453
       type Unit# :: GHC.Internal.Types.ZeroBitType
    
    4454 4454
       data Unit# = ...
    
    4455 4455
       getSolo :: forall a. Solo a -> a
    
    4456
    +  maxTupleSize :: GHC.Internal.Types.Int
    
    4456 4457
     
    
    4457 4458
     module GHC.Exception.Backtrace.Experimental where
    
    4458 4459
       -- Safety: None
    
    ... ... @@ -11044,6 +11045,7 @@ module Prelude.Experimental where
    11044 11045
       type Unit# :: GHC.Internal.Types.ZeroBitType
    
    11045 11046
       data Unit# = ...
    
    11046 11047
       getSolo :: forall a. Solo a -> a
    
    11048
    +  maxTupleSize :: GHC.Internal.Types.Int
    
    11047 11049
     
    
    11048 11050
     module System.Mem.Experimental where
    
    11049 11051
       -- Safety: None
    

  • testsuite/tests/interface-stability/ghc-prim-exports.stdout
    ... ... @@ -1232,6 +1232,7 @@ module GHC.Magic where
    1232 1232
       class DataToTag a where
    
    1233 1233
         dataToTag# :: a -> GHC.Internal.Prim.Int#
    
    1234 1234
         {-# MINIMAL dataToTag# #-}
    
    1235
    +  considerAccessible :: GHC.Internal.Types.Bool
    
    1235 1236
       inline :: forall a. a -> a
    
    1236 1237
       lazy :: forall a. a -> a
    
    1237 1238
       noinline :: forall a. a -> a
    
    ... ... @@ -3891,6 +3892,7 @@ module GHC.Tuple where
    3891 3892
       type Unit :: *
    
    3892 3893
       data Unit = ()
    
    3893 3894
       getSolo :: forall a. Solo a -> a
    
    3895
    +  maxTupleSize :: GHC.Internal.Types.Int
    
    3894 3896
     
    
    3895 3897
     module GHC.Types where
    
    3896 3898
       -- Safety: None