[Git][ghc/ghc][master] 2 commits: template-haskell: Move wired-ins to ghc-internal

Marge Bot (@marge-bot) gitlab at gitlab.haskell.org
Thu May 30 06:57:04 UTC 2024



Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC


Commits:
228dcae6 by Teo Camarasu at 2024-05-28T13:12:24+00:00
template-haskell: Move wired-ins to ghc-internal

Thus we make `template-haskell` reinstallable and keep it as the public
API for Template Haskell.
All of the wired-in identifiers are moved to `ghc-internal`.
This necessitates also moving much of `ghc-boot-th` into `ghc-internal`.
These modules are then re-exported from `ghc-boot-th` and
`template-haskell`.
To avoid a dependency on `template-haskell` from `lib:ghc`, we instead
depend on the TH ASTs via `ghc-boot-th`.

As `template-haskell` no longer has special status, we can drop the
logic adding an implicit dependency on `template-haskell` when using TH.
We can also drop the `template-haskell-next` package, which was
previously used when bootstrapping.

When bootstrapping, we need to vendor the TH AST modules from
`ghc-internal` into `ghc-boot-th`. This is controlled by the `bootstrap`
cabal flag as before. See Note [Bootstrapping Template Haskell].

We split out a GHC.Internal.TH.Lift module resolving #24752.
This module is only built when not bootstrapping.

Resolves #24703

-------------------------
Metric Increase:
    ghc_boot_th_dir
    ghc_boot_th_so
-------------------------

- - - - -
62dded28 by Teo Camarasu at 2024-05-28T13:12:24+00:00
testsuite: mark tests broken by #24886

Now that `template-haskell` is no longer wired-in.
These tests are triggering #24886, and so need to be marked broken.

- - - - -


30 changed files:

- .gitignore
- compiler/GHC/Builtin/Names/TH.hs
- compiler/GHC/Hs/Expr.hs
- compiler/GHC/HsToCore/Quote.hs
- compiler/GHC/Iface/Recomp.hs
- compiler/GHC/Plugins.hs
- compiler/GHC/Rename/Names.hs
- compiler/GHC/Rename/Splice.hs
- compiler/GHC/Runtime/Interpreter/JS.hs
- compiler/GHC/Tc/Errors/Ppr.hs
- compiler/GHC/Tc/Errors/Types.hs
- compiler/GHC/Tc/Gen/Splice.hs
- compiler/GHC/Tc/Gen/Splice.hs-boot
- compiler/GHC/Tc/Types/TH.hs
- compiler/GHC/ThToHs.hs
- compiler/GHC/Unit/State.hs
- compiler/GHC/Unit/Types.hs
- compiler/ghc.cabal.in
- hadrian/src/Packages.hs
- hadrian/src/Rules/Generate.hs
- hadrian/src/Rules/ToolArgs.hs
- hadrian/src/Settings/Default.hs
- hadrian/src/Settings/Packages.hs
- libraries/base/src/Control/Monad/IO/Class.hs
- libraries/base/src/Data/Array/Byte.hs
- libraries/base/src/Data/Fixed.hs
- libraries/ghc-boot-th/GHC/ForeignSrcLang/Type.hs
- libraries/template-haskell/Language/Haskell/TH/Lib/Map.hs → libraries/ghc-boot-th/GHC/Internal/TH/Lib/Map.hs
- + libraries/ghc-boot-th/GHC/Internal/TH/Ppr.hs
- + libraries/ghc-boot-th/GHC/Internal/TH/PprLib.hs


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/98597ad5fca81544d74f721fb508295fd2650232...62dded2895b0d4d6b8dc94e84aacbb9a99e19e5c

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/98597ad5fca81544d74f721fb508295fd2650232...62dded2895b0d4d6b8dc94e84aacbb9a99e19e5c
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/20240530/44e3d568/attachment.html>


More information about the ghc-commits mailing list