<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en" style="--code-editor-font: GitLab Mono, JetBrains Mono, Menlo, DejaVu Sans Mono, Liberation Mono, Consolas, Ubuntu Mono, Courier New, andale mono, lucida console, monospace;">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>
<style data-premailer="ignore" type="text/css">
a { color: #1068bf; }
</style>
<style>img {
max-width: 100%; height: auto;
}
body {
font-size: 0.875rem;
}
body {
-webkit-text-shadow: rgba(255,255,255,0.01) 0 0 1px;
}
body {
font-family: "GitLab Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans", Ubuntu, Cantarell, "Helvetica Neue", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; font-size: inherit;
}
</style>
</head>
<body style='font-size: inherit; -webkit-text-shadow: rgba(255,255,255,0.01) 0 0 1px; font-family: "GitLab Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans", Ubuntu, Cantarell, "Helvetica Neue", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";'>
<div class="content">
<h3 style="margin-top: 20px; margin-bottom: 10px;">
Ryan Scott pushed to branch wip/T23496-take-three at <a href="https://gitlab.haskell.org/ghc/ghc">Glasgow Haskell Compiler / GHC</a>
</h3>
<h4 style="margin-top: 10px; margin-bottom: 10px;">
Commits:
</h4>
<ul>
<li>
<strong style="font-weight: bold;"><a href="https://gitlab.haskell.org/ghc/ghc/-/commit/e7e9efcb6f24e0acb8d806edc67896fe790af518">e7e9efcb</a></strong>
<div>
<span> by Ryan Scott </span> <i> at 2023-07-14T09:25:48-04:00 </i>
</div>
<pre class="commit-message" style='white-space: pre-wrap; display: block; font-size: 14px; color: #333238; position: relative; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; word-break: break-all; word-wrap: break-word; background-color: #fbfafd; border-radius: 2px; margin: 0; padding: 8px 12px; border: 1px solid #dcdcde;'>Bump Cabal submodule
This bumps the `Cabal` submodule to bring in the changes from
https://github.com/haskell/cabal/pull/9071, which are a pre-requisite to
splitting out a `GHC.Generics.Internal` submodule from `GHC.Generics` (to be
done in a subsequent commit). Without these changes, compiling `Cabal` would
fail, since `Cabal-syntax`'s `Distribution.Compat.Prelude` was implicitly
relying on the bug documented in #23570, and when the modules are split apart,
the bug no longer triggers.
</pre>
</li>
<li>
<strong style="font-weight: bold;"><a href="https://gitlab.haskell.org/ghc/ghc/-/commit/bfd294442f2c9bc3e231532ae3f520ecbc14703e">bfd29444</a></strong>
<div>
<span> by Ryan Scott </span> <i> at 2023-07-14T09:27:20-04:00 </i>
</div>
<pre class="commit-message" style='white-space: pre-wrap; display: block; font-size: 14px; color: #333238; position: relative; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; word-break: break-all; word-wrap: break-word; background-color: #fbfafd; border-radius: 2px; margin: 0; padding: 8px 12px; border: 1px solid #dcdcde;'>Split GHC.Generics into two modules
Most of `GHC.Generics` has now been moved to `GHC.Generics.Internal`, which
`GHC.Generics` re-exports. The only things now defined in `GHC.Generics` are
the derived `Generic(1)` instances. These need to be put in a different module
because of GHC's new approach to dependency analysis used in a fix for #23496
(to be done in a subsequent commit), which is perfectly within its rights to
typecheck a generated `Rep` instance before it typechecks any of the
definitions that are referenced in the right-hand side of the instance.
Putting the definitions in a separate module from the derived `Generic`
instances (and therefore the generated `Rep` instances) is a sure-fire way to
ensure that this doesn't happen.
This causes a fair bit of churn in the expected output of test cases in the
test suite, but all of the changes are simply from switching to displaying
"`GHC.Generics.Internal`" instead of "`GHC.Generics`". Similarly, this bumps
the `haddock` submodule to bring in some changes to test cases in the Haddock
test suite.
</pre>
</li>
<li>
<strong style="font-weight: bold;"><a href="https://gitlab.haskell.org/ghc/ghc/-/commit/c955449e244a027fc12f86c387dac6be773aa27f">c955449e</a></strong>
<div>
<span> by Ryan Scott </span> <i> at 2023-07-14T09:27:20-04:00 </i>
</div>
<pre class="commit-message" style='white-space: pre-wrap; display: block; font-size: 14px; color: #333238; position: relative; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; word-break: break-all; word-wrap: break-word; background-color: #fbfafd; border-radius: 2px; margin: 0; padding: 8px 12px; border: 1px solid #dcdcde;'>deriving: Typecheck associated family instances before instance bindings
This is a significant overhaul of the way that `deriving` clauses and
standalone `deriving` declarations are typechecked. The highlights:
* Standalone `deriving` declarations are located in the new `DerivInstD`
constructor of `ClsInstDecl`, rather than as part of the `DerivD` constructor
of `HsGroup`. This move now means that standalone `deriving` instance
declarations are located alongside other forms of instance declarations,
which makes it easier to perform SCC analysis on them, as they are now part
of a `TyClGroup`.
* Now that everything `deriving`-related lives in `TyClGroup`s, we now
typecheck all of the associated type family instances that are generated from
`deriving` clauses/declarations first (in `tcTyClGroup`) _before_
typechecking any of the generated instance bindings, which happen after all
of the `TyClGroup`s have been processed. Doing so is essential to ensuring
that these associated type instances are in scope when needed to typecheck
other code in later `TyClGroup`s, such as the failing examples seen
in #23496. I have written an extensive `Note [Staging of deriving]` (previously
`Note [Staging of tcDeriving]`) to describe how everything works.
The second bullet point above involves quite a bit of churn in the expected
output of several test cases. This is for two reasons:
1. The order in which things are printed with `-ddump-deriv` is now different,
since `deriving`-related family instances are now generated earlier in the
typechecker.
2. If a test case errors out when typechecking a `deriving`-related family
instance, then GHC will stop there before printing any errors involving the
generated instance bindings. (Previously, both sorts of errors were printed
simultaneously.) As such, some expected-to-fail test cases do not print out
as many errors as before.
Fixes #23496.
</pre>
</li>
</ul>
<h4 style="margin-top: 10px; margin-bottom: 10px;">
23 changed files:
</h4>
<ul>
<li class="file-stats">
<a href="#0887cf39c5cdf9cf8d6758f410d7dab3023c0d77">
compiler/GHC/Builtin/Names.hs
</a>
</li>
<li class="file-stats">
<a href="#75bfcd03f3ba9315d33104fcb0424c6bfeb4e334">
compiler/GHC/Hs/Decls.hs
</a>
</li>
<li class="file-stats">
<a href="#9f00edfedb0f969865b049a78de3866545b4a60b">
compiler/GHC/Hs/Instances.hs
</a>
</li>
<li class="file-stats">
<a href="#9f8f154268a51dc39e1f608e6d9845fdae82d480">
compiler/GHC/Hs/Stats.hs
</a>
</li>
<li class="file-stats">
<a href="#7a1af22e4c32b9aa6ec708d9d3788e1c4db5da9a">
compiler/GHC/Hs/Utils.hs
</a>
</li>
<li class="file-stats">
<a href="#ea46b374e004d4416e29a563ee063542f98e48c5">
compiler/GHC/HsToCore/Docs.hs
</a>
</li>
<li class="file-stats">
<a href="#3c19c0be465f9a28d7b69f89c55648080fcc37eb">
compiler/GHC/HsToCore/Quote.hs
</a>
</li>
<li class="file-stats">
<a href="#649144a78135a23cabfc90dd83c4aabf448eb6ab">
compiler/GHC/Iface/Ext/Ast.hs
</a>
</li>
<li class="file-stats">
<a href="#bf951467d4a9aa443cb109cb4c84a2891945649b">
compiler/GHC/Parser.y
</a>
</li>
<li class="file-stats">
<a href="#7dd1cd0f6f2164a14c83d9aa564dd32bc30e447a">
compiler/GHC/Rename/Module.hs
</a>
</li>
<li class="file-stats">
<a href="#e05ee69330b0f7088f11a5f3567137547489664d">
compiler/GHC/Rename/Names.hs
</a>
</li>
<li class="file-stats">
<a href="#b768fdf8e0594bf98104ef18145fc9f16550bc06">
compiler/GHC/Tc/Deriv.hs
</a>
</li>
<li class="file-stats">
<a href="#e9a44bb2cab837a54e2701986ac773e814e49eab">
compiler/GHC/Tc/Deriv/Utils.hs
</a>
</li>
<li class="file-stats">
<a href="#e65390fa5a32c453a81a1c9a3e1c4464d155ca4a">
compiler/GHC/Tc/Module.hs
</a>
</li>
<li class="file-stats">
<a href="#83d23a46bb6cdc8b1edc16f1fd2c8f5c53e2c9ca">
compiler/GHC/Tc/TyCl.hs
</a>
</li>
<li class="file-stats">
<a href="#e63425e031ffe9350ee6b1687e506aaea75d11e1">
compiler/GHC/Tc/TyCl/Instance.hs
</a>
</li>
<li class="file-stats">
<a href="#f04235bf859e624dffc011ef839bc10f854d8bf9">
compiler/GHC/Tc/TyCl/Instance.hs-boot
</a>
</li>
<li class="file-stats">
<a href="#f021c52a6ccf306e88c9f760b2aee33b180ba341">
compiler/GHC/Tc/Utils/Env.hs
</a>
</li>
<li class="file-stats">
<a href="#2eac51f9871ca0c0698aa1fc7f79c05ef8fc4a49">
compiler/GHC/ThToHs.hs
</a>
</li>
<li class="file-stats">
<a href="#997b81d43f8807b1b83ca6cc7c52b367982f2bf7">
compiler/Language/Haskell/Syntax/Decls.hs
</a>
</li>
<li class="file-stats">
<a href="#55fd4da29695073f23c02f21476e753eb7c467b4">
compiler/Language/Haskell/Syntax/Extension.hs
</a>
</li>
<li class="file-stats">
<a href="#2b3a5da6af2421fdb559def8637e7fac0436609f">
libraries/Cabal
</a>
</li>
<li class="file-stats">
<a href="#ca474770fd1919cad63c4bbfe1236b4862eada45">
libraries/base/GHC/Generics.hs
</a>
</li>
</ul>
<h5 style="margin-top: 10px; margin-bottom: 10px; font-size: 0.875rem;">
The diff was not included because it is too large.
</h5>
</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #737278;">
—
<br>
<a href="https://gitlab.haskell.org/ghc/ghc/-/compare/57f0ceb5ff6059df0a4f229cd143c8af247feef5...c955449e244a027fc12f86c387dac6be773aa27f">View it on GitLab</a>.
<br>
You're receiving this email because of your account on <a target="_blank" rel="noopener noreferrer" href="https://gitlab.haskell.org">gitlab.haskell.org</a>. <a href="https://gitlab.haskell.org/-/profile/notifications" target="_blank" rel="noopener noreferrer" class="mng-notif-link">Manage all notifications</a> · <a href="https://gitlab.haskell.org/help" target="_blank" rel="noopener noreferrer" class="help-link">Help</a>
</p>
</div>
</body>
</html>