[Git][ghc/ghc][wip/ghc-internals-2] 2 commits: ghc-internals: Initial commit of the skeleton

Ben Gamari (@bgamari) gitlab at gitlab.haskell.org
Thu Jul 20 01:26:02 UTC 2023



Ben Gamari pushed to branch wip/ghc-internals-2 at Glasgow Haskell Compiler / GHC


Commits:
12b230b5 by Ben Gamari at 2023-07-19T21:25:52-04:00
ghc-internals: Initial commit of the skeleton

- - - - -
aa77de4c by Ben Gamari at 2023-07-19T21:25:53-04:00
ghc-experimental: Initial commit

- - - - -


11 changed files:

- hadrian/src/Packages.hs
- hadrian/src/Settings/Default.hs
- libraries/base/base.cabal
- + libraries/ghc-experimental/CHANGELOG.md
- + libraries/ghc-experimental/LICENSE
- + libraries/ghc-experimental/ghc-experimental.cabal
- + libraries/ghc-experimental/src/Dummy.hs
- + libraries/ghc-internals/CHANGELOG.md
- + libraries/ghc-internals/LICENSE
- + libraries/ghc-internals/ghc-internals.cabal
- + libraries/ghc-internals/src/Dummy.hs


Changes:

=====================================
hadrian/src/Packages.hs
=====================================
@@ -5,7 +5,8 @@ module Packages (
     checkExact, countDeps,
     compareSizes, compiler, containers, deepseq, deriveConstants, directory, dumpDecls,
     exceptions, filepath, genapply, genprimopcode, ghc, ghcBignum, ghcBoot, ghcBootTh, ghcPlatform,
-    ghcCompact, ghcConfig, ghcHeap, ghci, ghciWrapper, ghcPkg, ghcPrim, haddock, haskeline,
+    ghcCompact, ghcConfig, ghcExperimental, ghcHeap, ghcInternals,
+    ghci, ghciWrapper, ghcPkg, ghcPrim, haddock, haskeline,
     hsc2hs, hp2ps, hpc, hpcBin, integerGmp, integerSimple, iserv, iservProxy,
     libffi, mtl, parsec, pretty, primitive, process, remoteIserv, rts,
     runGhc, semaphoreCompat, stm, templateHaskell, terminfo, text, time, timeout, touchy,
@@ -37,7 +38,8 @@ ghcPackages =
     [ array, base, binary, bytestring, cabalSyntax, cabal, checkPpr, checkExact, countDeps
     , compareSizes, compiler, containers, deepseq, deriveConstants, directory, dumpDecls
     , exceptions, filepath, genapply, genprimopcode, ghc, ghcBignum, ghcBoot, ghcBootTh, ghcPlatform
-    , ghcCompact, ghcConfig, ghcHeap, ghci, ghciWrapper, ghcPkg, ghcPrim, haddock, haskeline, hsc2hs
+    , ghcCompact, ghcConfig, ghcExperimental, ghcHeap, ghcInternals
+    , ghci, ghciWrapper, ghcPkg, ghcPrim, haddock, haskeline, hsc2hs
     , hp2ps, hpc, hpcBin, integerGmp, integerSimple, iserv, libffi, mtl
     , parsec, pretty, process, rts, runGhc, stm, semaphoreCompat, templateHaskell
     , terminfo, text, time, touchy, transformers, unlit, unix, win32, xhtml
@@ -53,7 +55,8 @@ isGhcPackage = (`elem` ghcPackages)
 array, base, binary, bytestring, cabalSyntax, cabal, checkPpr, checkExact, countDeps,
   compareSizes, compiler, containers, deepseq, deriveConstants, directory, dumpDecls,
   exceptions, filepath, genapply, genprimopcode, ghc, ghcBignum, ghcBoot, ghcBootTh, ghcPlatform,
-  ghcCompact, ghcConfig, ghcHeap, ghci, ghciWrapper, ghcPkg, ghcPrim, haddock, haskeline, hsc2hs,
+  ghcCompact, ghcConfig, ghcExperimental, ghcHeap, ghcInternals,
+  ghci, ghciWrapper, ghcPkg, ghcPrim, haddock, haskeline, hsc2hs,
   hp2ps, hpc, hpcBin, integerGmp, integerSimple, iserv, iservProxy, remoteIserv, libffi, mtl,
   parsec, pretty, primitive, process, rts, runGhc, semaphoreCompat, stm, templateHaskell,
   terminfo, text, time, touchy, transformers, unlit, unix, win32, xhtml,
@@ -87,7 +90,9 @@ ghcBootTh           = lib  "ghc-boot-th"
 ghcPlatform         = lib  "ghc-platform"
 ghcCompact          = lib  "ghc-compact"
 ghcConfig           = prg  "ghc-config"      `setPath` "testsuite/ghc-config"
+ghcExperimental     = lib  "ghc-experimental"
 ghcHeap             = lib  "ghc-heap"
+ghcInternals        = lib  "ghc-internals"
 ghci                = lib  "ghci"
 ghciWrapper         = prg  "ghci-wrapper"    `setPath` "driver/ghci"
                       -- See Note [Hadrian's ghci-wrapper package]


=====================================
hadrian/src/Settings/Default.hs
=====================================
@@ -135,6 +135,8 @@ stage1Packages = do
         , ghc
         , ghcBignum
         , ghcCompact
+        , ghcExperimental
+        , ghcInternals
         , ghcPkg
         , ghcPrim
         , haskeline


=====================================
libraries/base/base.cabal
=====================================
@@ -87,6 +87,7 @@ Library
     build-depends:
         rts == 1.0.*,
         ghc-prim >= 0.5.1.0 && < 0.11,
+        ghc-internals >= 0.1 && < 0.2,
         ghc-bignum >= 1.0 && < 2.0
 
     exposed-modules:


=====================================
libraries/ghc-experimental/CHANGELOG.md
=====================================
@@ -0,0 +1,5 @@
+# Revision history for ghc-experimental
+
+## 0.1.0.0 -- YYYY-mm-dd
+
+* First version. Released on an unsuspecting world.


=====================================
libraries/ghc-experimental/LICENSE
=====================================
@@ -0,0 +1,30 @@
+Copyright (c) 2023, ghc-devs at haskell.org
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+    * Redistributions of source code must retain the above copyright
+      notice, this list of conditions and the following disclaimer.
+
+    * Redistributions in binary form must reproduce the above
+      copyright notice, this list of conditions and the following
+      disclaimer in the documentation and/or other materials provided
+      with the distribution.
+
+    * Neither the name of ghc-devs at haskell.org nor the names of other
+      contributors may be used to endorse or promote products derived
+      from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


=====================================
libraries/ghc-experimental/ghc-experimental.cabal
=====================================
@@ -0,0 +1,31 @@
+cabal-version:      3.0
+name:               ghc-experimental
+version:            0.1.0.0
+synopsis:           Experimental features of GHC's standard library
+description:
+    This package is where experimental GHC standard library interfaces start
+    life as they mature. Eventually, stabilized interfaces will be
+    migrated into the @base@ library.
+
+homepage:           https://www.haskell.org/ghc/
+license:            BSD-3-Clause
+license-file:       LICENSE
+author:             The GHC Team
+maintainer:         ghc-devs at haskell.org
+copyright:          (c) 2023 The GHC Team
+category:           Development
+build-type:         Simple
+extra-doc-files:    CHANGELOG.md
+
+common warnings
+    ghc-options: -Wall
+
+library
+    import:           warnings
+    exposed-modules:  
+    other-modules:    Dummy
+    other-extensions:
+    build-depends:    base ^>=4.18,
+                      ghc-internals >= 0.1 && < 0.2
+    hs-source-dirs:   src
+    default-language: Haskell2010


=====================================
libraries/ghc-experimental/src/Dummy.hs
=====================================
@@ -0,0 +1,10 @@
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- | This module merely serves as a placeholder since
+-- Haskell packages must contain at least one module.
+-- This can be dropped once a real module has been introduced to
+-- @ghc-experimental at .
+module Dummy () where
+
+-- for build system ordering
+import GHC.Base ()


=====================================
libraries/ghc-internals/CHANGELOG.md
=====================================
@@ -0,0 +1,5 @@
+# Revision history for ghc-internals
+
+## 0.1.0.0 -- YYYY-mm-dd
+
+* First version. Released on an unsuspecting world.


=====================================
libraries/ghc-internals/LICENSE
=====================================
@@ -0,0 +1,30 @@
+Copyright (c) 2023, Ben Gamari
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+    * Redistributions of source code must retain the above copyright
+      notice, this list of conditions and the following disclaimer.
+
+    * Redistributions in binary form must reproduce the above
+      copyright notice, this list of conditions and the following
+      disclaimer in the documentation and/or other materials provided
+      with the distribution.
+
+    * Neither the name of Ben Gamari nor the names of other
+      contributors may be used to endorse or promote products derived
+      from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


=====================================
libraries/ghc-internals/ghc-internals.cabal
=====================================
@@ -0,0 +1,33 @@
+cabal-version:      3.0
+name:               ghc-internals
+version:            0.1.0.0
+synopsis:
+    Internal implementation of the Glasgow Haskell Compiler's standard library
+description:
+    This is an internal package containing the implementation of the Glasgow
+    Haskell Compiler's standard library. End users should not depend upon this
+    package directly but rather use either @base@ or the @ghc-experimental@
+    packages.
+homepage:           https://www.haskell.org/ghc/
+license:            BSD-3-Clause
+license-file:       LICENSE
+author:             The GHC Team
+maintainer:         ghc-devs at haskell.org
+copyright:          (c) 2023 The GHC Team
+category:           Development
+build-type:         Simple
+extra-doc-files:    CHANGELOG.md
+
+common warnings
+    ghc-options: -Wall
+
+library
+    import:           warnings
+    exposed-modules:  
+    other-modules:    Dummy
+    other-extensions:
+    build-depends:    rts == 1.0.*,
+                      ghc-prim >= 0.5.1.0 && < 0.11,
+                      ghc-bignum >= 1.0 && < 2.0
+    hs-source-dirs:   src
+    default-language: Haskell2010


=====================================
libraries/ghc-internals/src/Dummy.hs
=====================================
@@ -0,0 +1,11 @@
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- | This module merely serves as a placeholder since
+-- Haskell packages must contain at least one module.
+-- This can be dropped once a real module has been introduced to
+-- @ghc-internals at .
+module Dummy () where
+
+-- for build system dependency ordering
+import GHC.Types ()
+import GHC.Num.BigNat ()



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/8a7d7ff7f7ecd452dd7ef77193f480287e1d385d...aa77de4cde6943a8a234167b8d79973a5c8d2671

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/8a7d7ff7f7ecd452dd7ef77193f480287e1d385d...aa77de4cde6943a8a234167b8d79973a5c8d2671
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230719/54e090d5/attachment-0001.html>


More information about the ghc-commits mailing list