[Git][ghc/ghc][wip/jade/ast] 15 commits: Demand: Combine examples into Note (#25107)

Hassan Al-Awwadi (@hassan.awwadi) gitlab at gitlab.haskell.org
Wed Sep 25 14:39:51 UTC 2024



Hassan Al-Awwadi pushed to branch wip/jade/ast at Glasgow Haskell Compiler / GHC


Commits:
9e96dad8 by Sebastian Graf at 2024-09-21T17:47:59-04:00
Demand: Combine examples into Note (#25107)

Just a leftover from !13060.

Fixes #25107.

- - - - -
21aaa34b by sheaf at 2024-09-21T17:48:36-04:00
Use x86_64-unknown-windows-gnu target for LLVM on Windows

- - - - -
992a7624 by sheaf at 2024-09-21T17:48:36-04:00
LLVM: use -relocation-model=pic on Windows

This is necessary to avoid the segfaults reported in #22487.

Fixes #22487

- - - - -
c50d29be by Ryan Hendrickson at 2024-09-21T17:49:15-04:00
compiler: Use type abstractions when deriving

For deriving newtype and deriving via, in order to bring type variables
needed for the coercions into scope, GHC generates type signatures for
derived class methods. As a simplification, drop the type signatures and
instead use type abstractions to bring method type variables into scope.

- - - - -
f04fd0ae by Zubin Duggal at 2024-09-21T17:49:51-04:00
driver: Ensure we run driverPlugin for staticPlugins (#25217)

driverPlugins are only run when the plugin state changes. This meant they were
never run for static plugins, as their state never changes.

We need to keep track of whether a static plugin has been initialised to ensure
we run static driver plugins at least once. This necessitates an additional field
in the `StaticPlugin` constructor as this state has to be bundled with the plugin
itself, as static plugins have no name/identifier we can use to otherwise reference
them

- - - - -
620becd7 by Andreas Klebinger at 2024-09-21T17:50:27-04:00
Allow unknown fd device types for setNonBlockingMode.

This allows fds with a unknown device type to have blocking mode
set. This happens for example for fds from the inotify subsystem.

Fixes #25199.

- - - - -
c76e25b3 by Hécate Kleidukos at 2024-09-21T17:51:07-04:00
Use Hackage version of Cabal 3.14.0.0 for Hadrian.
We remove the vendored Cabal submodule.

Also update the bootstrap plans

Fixes #25086

- - - - -
6c83fd7f by Zubin Duggal at 2024-09-21T17:51:07-04:00
ci: Ensure we source ci.sh in any jobs that run commands outside of ci.sh

ci.sh sets up the toolchain environment, including paths for the cabal directory, the
toolchain binaries etc. If we run any commands outside of ci.sh, unless we
source ci.sh we will use the wrong values for these environment variables.

In particular, I ran into an issue where the cabal invocation `hadrian/ghci` was
using an old index state despite `ci.sh setup` updating and setting the correct
index state. This is because `ci.sh` sets the `CABAL_DIR` to a different place, which
is where the index was downloaded to, but we were using the default cabal directory
outside ci.sh

The solution is to source the correct environment `ci.sh` using `. ci.sh setup`

- - - - -
9586998d by Sven Tennie at 2024-09-21T17:51:43-04:00
ghc-toolchain: Set -fuse-ld even for ld.bfd

This reflects the behaviour of the autoconf scripts.

- - - - -
d7016e0d by Sylvain Henry at 2024-09-21T17:52:24-04:00
Parser: be more careful when lexing extended literals (#25258)

Previously we would lex invalid prefixes like "8#Int3" as [8#Int, 3].

A side-effect of this patch is that we now allow negative unsigned
extended literals. They trigger an overflow warning later anyway.

- - - - -
ca67d7cb by Zubin Duggal at 2024-09-22T02:34:06-04:00
rts: Ensure we dump new Cost Centres added by freshly loaded objects to the eventlog.

To do this, we keep track of the ID of the last cost centre we dumped in DUMPED_CC_ID,
and call dumpCostCentresToEventLog from refreshProfilingCCSs, which will dump all the new
cost centres up to the one we already dumped in DUMPED_CC_ID.

Fixes #24148

- - - - -
c0df5aa9 by Alan Zimmerman at 2024-09-22T02:34:42-04:00
EPA: Replace AnnsModule am_main with EpTokens

Working towards removing `AddEpAnn`

- - - - -
f4cb5db9 by Jade at 2024-09-25T16:39:36+02:00
Refactor FieldOcc vs AmbiguousFieldOcc with TTG

Improves the design of FieldOcc vs AmbiguousFieldOcc, and removes a
dependency on `RdrName` from the Language.Haskell.* namespace (#21592).

The design:

* The FieldOcc constructor of FieldOcc always refers to an unambiguous
  field occurrence.
* During renaming, a FieldOcc may be ambiguous and only be resolvable
  during Typechecking
* Therefore, we extend (with TTG) `FieldOcc GhcRn` with a constructor
  `AmbiguousFieldOcc` that constructs a definitely ambiguous `FieldOcc`.
* During typechecking, all ambiguous field occurrences must be resolved,
  so the `AmbiguousFieldOcc` constructor no longer exists

See Note [Lifecycle of a FieldOcc]

Co-authored-by: Rodrigo Mesquita <rodrigo.m.mesquita at gmail.com>

- - - - -
20bc6759 by Hassan Al-Awwadi at 2024-09-25T16:39:36+02:00
Wrangled until everything compiled.

There are two issues:
- FieldOcc used to only have one constructor and always be unambigious, this is no longer the case. Calls to foLabel are thus partial now. Don't know how much we care about this, since the partial calls are mostly inside functions that used to operate on the operate on the unambigious FieldOcc
- Lots of functions that take in a FieldOcc, or a HsExpr (with the HsRecSel constructor) now have a new case. It was not always clear to me what the correct implementation was for these. I have filled them in as far as I could and left one undefined...

- - - - -
02c78124 by Hassan Al-Awwadi at 2024-09-25T16:39:36+02:00
fixed ambiguity regression

- - - - -


30 changed files:

- .gitignore
- .gitlab-ci.yml
- .gitlab/ci.sh
- .gitmodules
- compiler/GHC/Core/Opt/DmdAnal.hs
- compiler/GHC/Data/StringBuffer.hs
- compiler/GHC/Driver/Pipeline/Execute.hs
- compiler/GHC/Driver/Plugins.hs
- compiler/GHC/Hs.hs
- compiler/GHC/Hs/Binds.hs
- compiler/GHC/Hs/Extension.hs
- compiler/GHC/Hs/Instances.hs
- compiler/GHC/Hs/Pat.hs
- compiler/GHC/Hs/Syn/Type.hs
- compiler/GHC/Hs/Type.hs
- compiler/GHC/Hs/Utils.hs
- compiler/GHC/HsToCore/Docs.hs
- compiler/GHC/HsToCore/Expr.hs
- compiler/GHC/HsToCore/Quote.hs
- compiler/GHC/HsToCore/Ticks.hs
- compiler/GHC/Iface/Ext/Ast.hs
- compiler/GHC/Parser.y
- compiler/GHC/Parser/Lexer.x
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Rename/Bind.hs
- compiler/GHC/Rename/Env.hs
- compiler/GHC/Rename/Expr.hs
- compiler/GHC/Rename/Fixity.hs
- compiler/GHC/Rename/HsType.hs
- compiler/GHC/Rename/Pat.hs


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/4775c0facf18503d21a5544fb61b51f0129ef946...02c781249e01800380ddab8d8bb3ff9df9b03ad2

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/4775c0facf18503d21a5544fb61b51f0129ef946...02c781249e01800380ddab8d8bb3ff9df9b03ad2
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/20240925/4e196217/attachment.html>


More information about the ghc-commits mailing list