| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
| |
Includes a fix for wasm support, doesn't impact other targets.
|
|
|
|
| |
Includes a fix for wasm support, doesn't impact other targets.
|
|
|
|
| |
ci-images has recently been updated, including changes needed for wasm32-wasi CI.
|
|
|
|
| |
Fixes #22098
|
|
|
|
|
|
|
|
|
|
| |
Also bumps process and ghc-boot bounds on unix.
For hadrian, when cross-compiling, we add -Wwarn=unused-imports
-Wwarn=unused-top-binds to validation flavour. Further fixes in unix
and/or hsc2hs is needed to make it completely free of warnings; for
the time being, this change is needed to unblock other
cross-compilation related work.
|
|
|
|
|
|
|
| |
Pass FastStrings to functions directly, to make sure the rule
for fsLit "literal" fires.
Remove SDoc indirection in GHCi.UI.Tags and GHC.Unit.Module.Graph.
|
|
|
|
|
|
|
| |
Since lint-submods doesn't run in nightlies, hadrian-ghc-in-ghci needs
to mark it as "optional" so it can run if the job doesn't exist.
Fixes #22396.
|
|
|
|
|
| |
Introduces GHC.Prelude.Basic which can be used in modules which are a
dependency of the ppr code.
|
| |
|
|
|
|
|
|
|
|
|
| |
Gergo points out that these bindings are tidied, rather than prepd as
the variable claims. Therefore we update the name of the variable to
reflect reality and add a comment to the data type to try to erase any
future confusion.
Fixes #22307
|
|
|
|
| |
Cleans up git status if one sets -fwrite-ide-info in hadrian/ghci.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit ports the numeric tests which found a regression in GHC-9.4.
https://github.com/haskell-foundation/foundation/issues/571
Included in the commit is a simple random number generator and
simplified QuickCheck implementation. In future these could be factored
out of this standalone file and reused as a general purpose library
which could be used for other QuickCheck style tests in the testsuite.
See #22282
|
|
|
|
|
|
|
|
|
| |
Currently it is only used by the make build system, which is soon to be
retired, and it has not built since 41cf758b. We may need to reintroduce
it when dynamic-linking support is introduced on Windows, but we will
cross that bridge once we get there.
Fixes #21753.
|
| |
|
|
|
|
| |
See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
|
|
|
|
|
| |
See: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-returns_005fnonnull-function-attribute
See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
|
|
|
|
|
|
|
|
| |
This patch adds the `STG_ALLOC_SIZE1` and `STG_ALLOC_SIZE2` macros which
allow to set the `alloc_size` attribute on functions, when available.
See: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-alloc_005fsize-function-attribute
See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch adds a new `STG_MALLOC1` macro (and its counterpart
`STG_MALLOC2` for completeness) which allows to specify the deallocation
function to be used with allocations of allocating functions, and
applies it to `stg*allocBytes`.
It also fixes a case where `free` was used to free up an
`stgMallocBytes` allocation, found by the above change.
See: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-malloc-function-attribute
See: https://gitlab.haskell.org/ghc/ghc/-/issues/22381
|
| |
|
|
|
|
|
| |
Instead of using `GNUC3_ATTRIBUTE(__malloc__)`, provide a `STG_MALLOC`
macro definition and use it instead.
|
|
|
|
|
| |
Similar to `STG_UNUSED`, have a specific macro for
`__attribute__(used)`.
|
| |
|
|
|
|
|
|
|
| |
Instead of sprinkling the codebase with
`GNU(C3)_ATTRIBUTE(__noreturn__)`, add a `STG_NORETURN` macro (for,
basically, the same thing) similar to `STG_UNUSED` and others, and
update the code to use this macro where applicable.
|
| |
|
|
|
|
|
| |
Ryan Scott offered a cut-down repro case
(60 lines instead of more than 700 lines)
|
| |
|
|
|
|
|
|
|
| |
Ticket #22379 revealed that skolemiseQuantifiedTyVar was
dropping the passed-in skol_info on the floor when it encountered
a SkolemTv. Bad! Several TyCons thereby share a single SkolemInfo
on their binders, which lead to bogus error reports.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before this patch, when converting from TH.Exp to LHsExpr GhcPs,
the compiler inserted more parentheses than required:
((f a) (b + c)) d
This was happening because the LHS of the function application was
parenthesized as if it was the RHS.
Now we use funPrec and appPrec appropriately and produce sensibly
parenthesized expressions:
f a (b + c) d
I also took the opportunity to remove the special case for LamE,
which was not special at all and simply duplicated code.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since ee0deb805, the use of `pthread_setname_np` on Darwin was fixed
when invoking `createOSThread`. However, the 'ticker' has some
thread-creation code which doesn't rely on `createOSThread`, yet also
uses `pthread_setname_np`.
This patch enforces all thread creation to go through a single
function, which uses the (correct) thread-naming code introduced in
ee0deb805.
See: https://gitlab.haskell.org/ghc/ghc/-/commit/ee0deb8054da2a597fc5624469b4c44fd769ada2
See: https://gitlab.haskell.org/ghc/ghc/-/issues/22206
See: https://gitlab.haskell.org/ghc/ghc/-/merge_requests/9066
|
|
|
|
|
|
|
|
|
|
| |
Since, unlike the code in ee0deb8054da2^, usage of the `name` value
passed to `createOSThread` now outlives said function's lifetime, and
could hence be released by the caller by the time the new thread runs
`start_thread`, it needs to be copied.
See: https://gitlab.haskell.org/ghc/ghc/-/commit/ee0deb8054da2a597fc5624469b4c44fd769ada2#note_460080
See: https://gitlab.haskell.org/ghc/ghc/-/merge_requests/9066
|
|
|
|
|
|
|
|
|
|
| |
Since we don't intend to ever change the incoming string, declare this
to be true.
Also, in the POSIX implementation, the argument is no longer `STG_UNUSED`
(since ee0deb8054da2a597fc5624469b4c44fd769ada2) in any code path.
See: https://gitlab.haskell.org/ghc/ghc/-/commit/ee0deb8054da2a597fc5624469b4c44fd769ada2#note_460080
|
| |
|
| |
|
|
|
|
| |
Fixes #22325
|
|
|
|
|
|
|
|
|
|
|
| |
* Rename pprCLabel to pprCLabelStyle, and use the name pprCLabel
for a function using CStyle (analogous to pprAsmLabel)
* Move LabelStyle to the CLabel module, it no longer needs to be in Outputable.
* Move calls to 'text' right next to literals, to make sure the text/str
rule is triggered.
* Remove FastString/String roundtrip in Tc.Deriv.Generate
* Introduce showSDocForUser', which abstracts over a pattern in
GHCi.UI
|
|
|
|
| |
It used to pick the db for stage-2 which obviously didn't work.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
I had forgotten to add the auxiliary dict bindings to the
/unfolding/ of a specialised function. This caused #22358,
which reports failures when compiling Hackage packages
fixed-vector
indexed-traversable
Regression test T22357 is snarfed from indexed-traversable
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change aims to minimize source location information leaking
into interface files, which makes ABI hashes dependent on the
build location.
The `Binary (Located a)` instance has been removed completely.
It seems that the HIE interface still needs the ability to
serialize SrcSpans, but by wrapping the instances, it should
be a lot more difficult to inadvertently add source location
information.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When faced with VDQ in the type of a term, GHC generates the following
error message:
Illegal visible, dependent quantification in the type of a term
(GHC does not yet support this)
Prior to this patch, there were two ways this message could have been
generated and represented:
1. with the dedicated constructor TcRnVDQInTermType
(see check_type in GHC.Tc.Validity)
2. with the transitional constructor TcRnUnknownMessage
(see noNestedForallsContextsErr in GHC.Rename.Utils)
Not only this led to duplication of code generating the final SDoc,
it also made it tricky to track the origin of the error message.
This patch fixes the problem by using TcRnVDQInTermType exclusively.
|
|
|
|
|
| |
Necessary for newer cross-compiling backends (JS, Wasm) that don't
support TH yet.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before this patch, GHC used withHsDocContext to attach an HsDocContext
to an error message:
addErr $ mkTcRnUnknownMessage $ mkPlainError noHints (withHsDocContext ctxt msg)
The problem with this approach is that it only works with
TcRnUnknownMessage. But could we attach an HsDocContext to a
structured error message in a generic way? This patch solves
the problem by introducing a new constructor to TcRnMessage:
data TcRnMessage where
...
TcRnWithHsDocContext :: !HsDocContext -> !TcRnMessage -> TcRnMessage
...
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch fixes two distinct (but closely related) buglets that were uncovered
in #22235:
* `liftEnvSubst` used an empty in-scope set, which was not wide enough to cover
the variables in the range of the substitution. This patch fixes this by
populating the in-scope set from the free variables in the range of the
substitution.
* `composeTCvSubst` applied the first substitution argument to the range of the
second substitution argument, but the first substitution's in-scope set was
not wide enough to cover the range of the second substutition. We similarly
fix this issue in this patch by widening the first substitution's in-scope set
before applying it.
Fixes #22235.
|
|
|
|
|
|
|
| |
Remove unused mkPtrString and isUnderscoreFS.
We no longer use mkPtrString since 1d03d8bef96.
Remove unnecessary conversions between FastString and String and back.
|
|
|
|
|
|
| |
Fixes #22311.
Thanks to @zeldin for the patch.
|
|
|
|
| |
Move doCpp out of the driver to be able to use it in the upcoming JS backend.
|
|
|
|
|
| |
The comment applies only when host's word size < target's word size.
So we can relax the guard.
|