- Dec 21, 2017
-
-
Ryan Scott authored
Summary: The `HsType` pretty-printer does not automatically insert parentheses where necessary for type applications, so a function `isCompoundHsType` was created in D4056 towards this purpose. However, it was not used in as many places as it ought to be, resulting in #14578. Test Plan: make test TEST=T14578 Reviewers: alanz, bgamari, simonpj Reviewed By: alanz, simonpj Subscribers: simonpj, rwbarton, thomie, carter GHC Trac Issues: #14578 Differential Revision: https://phabricator.haskell.org/D4266
-
- Dec 20, 2017
-
-
Herbert Valerio Riedel authored
[skip ci] (cherry picked from commit 00565677)
-
- Dec 19, 2017
-
-
Simon Peyton Jones authored
This is a tiny refactoring that removes one of the calls to mkStatePrimTy, in service to Trac #14596
-
Simon Peyton Jones authored
Triggered by thinking about Trac #14596, I found that runRW# does not need to be a "magic" wired-in Id, now that we have levity polymorphism. This patch stops it being wired-in.
-
Gabor Greif authored
-
- Dec 18, 2017
-
-
Gabor Greif authored
-
Ben Gamari authored
-
Ben Gamari authored
-
Test Plan: validate Reviewers: bgamari, niteria, erikd, dfeuer Reviewed By: dfeuer Subscribers: Yuras, dfeuer, rwbarton, thomie, carter GHC Trac Issues: #14497 Differential Revision: https://phabricator.haskell.org/D4254
-
Simon Peyton Jones authored
This patch fixes Trac #14998, where we eventually decided that the existential type variables of the signature of a pattern synonym should not scope over the pattern synonym. See Note [Pattern synonym existentials do not scope] in TcPatSyn.
-
Simon Peyton Jones authored
-
Simon Peyton Jones authored
This fixes Trac #14591 I took the opportunity to delete the dead code isMonadCompExpr
-
- Dec 15, 2017
-
-
Richard Eisenberg authored
The fix for #11203 prohibits duplicate SigTvs in non-CUSK kind signatures by checking for duplicates after type inference is done. This works well. GHC also checks for duplicate SigTvs after working with partial type signatures (another place where SigTvs arise). However, neither fix eliminates this whole class of problems (because doing so would be heavier than we would like). So, this comment adds a warning to users of newSigTyVar to be aware of problems with duplicates.
-
Simon Peyton Jones authored
This patch fixes an outright bug in tcDataKindSig, shown up in Trac of a data type declaration. See Note [TyConBinders for the result kind signature of a data type] I also took the opportunity to elminate the DataKindCheck argument and data type from tcDataKindSig, instead moving the check to the call site, which is easier to understand.
-
- Dec 14, 2017
-
-
Ben Gamari authored
(cherry picked from commit 15b2b959)
-
Ben Gamari authored
(cherry picked from commit fdccc666)
-
We filter the complete patterns given in a COMPLETE set to only those that subsume the type we are matching. Otherwise we end up introducing an ill-typed equation into the overlap checking, provoking a crash. This was the cause of Trac #14135. Reviewers: austin, bgamari, mpickering, gkaracha, simonpj, RyanGlScott, carlostome Reviewed By: bgamari Subscribers: carter, dfeuer, RyanGlScott, goldfire, rwbarton, thomie GHC Trac Issues: #14135 Differential Revision: https://phabricator.haskell.org/D3981
-
Gabor Greif authored
-
Simon Peyton Jones authored
-
Simon Peyton Jones authored
Trac #14554 showed up an outright bug in the unflattening code in TcFlatten. I was filling in a coercion with the wrong coercion (a Syn in the wrong place). Result: "Bad coercion hole" assertion failures, and Core Lint Errors. Easily fixed, and the code is simpler too.
-
Simon Peyton Jones authored
-
- Dec 13, 2017
-
-
Gabor Greif authored
-
Simon Peyton Jones authored
The typechecker has the invariant that every type should be well-kinded as it stands, without zonking. See Note [The well-kinded type invariant] in TcType. That invariant was not being upheld, which led to Trac #14174. I fixed part of it, but T14174a showed that there was more. This patch finishes the job. * See Note [The tcType invariant] in TcHsType, which articulates an invariant that was very nearly, but not quite, true. One place that falisified it was the HsWildCardTy case of tc_hs_type, so I fixed that. * mkNakedCastTy now makes no attempt to eliminate casts; indeed it cannot lest it break Note [The well-kinded type invariant]. The prior comment suggested that it was crucial for performance but happily it seems not to be. The extra Refls are eliminated by the zonker. * I found I could tidy up TcHsType.instantiateTyN and instantiateTyUntilN by eliminating one of its parameters. That led to a cascade of minor improvements in TcTyClsDecls. Hooray.
-
Simon Peyton Jones authored
Bytes allocated has fallen by around 5%. I think this due to some of my recent refactoring of the typechecker, but I'm not certain about exactly which change did it. Good though!
-
Simon Peyton Jones authored
-
Simon Peyton Jones authored
Two things here: * While debugging Trac #14561 I found it hard to understand ghcPrimIds and magicIds in MkId. This patch adds more structure and comments. * I also discovered that ($) no longer needs to be a wiredInId because we now have levity polymorphism. So I took dollarId out of MkId; and gave it a levity-polymorphic type in GHC.Base
-
Simon Peyton Jones authored
This bug was shown up by Trac #14561. The deguarer carefully detects unsaturated and levity-polymorphic uses of primops, but not of things like unsafeCoerce#. The fix is simple: see Note [Levity-polymorphic Ids] in Id.
-
Simon Peyton Jones authored
This refactoring has no change in behaviour but makes the structure clearer
-
- Dec 12, 2017
-
-
Ryan Scott authored
This adds a regression test for the original program in #14040. This does not fix #14040 entirely, though, as the program in https://ghc.haskell.org/trac/ghc/ticket/14040#comment:2 still panics, so there is more work to be done there.
-
- Dec 11, 2017
-
-
Reviewers: bgamari, austin, hvr, dfeuer Reviewed By: dfeuer Subscribers: syd, dfeuer, rwbarton, thomie Differential Revision: https://phabricator.haskell.org/D4012
-
Reviewers: bgamari, Phyx, austin, hvr, simonmar Reviewed By: bgamari Subscribers: syd, rwbarton, thomie Differential Revision: https://phabricator.haskell.org/D4041
-
David Feuer authored
* Add a new flag, `-fignore-optim-changes`, allowing them to avoid recompilation if the only changes are to the `-O` level or to flags controlling optimizations. * When `-fignore-optim-changes` is *off*, recompile when optimization flags (e.g., `-fno-full-laziness`) change. Previously, we ignored these unconditionally when deciding whether to recompile a module. Reviewers: austin, bgamari, simonmar Reviewed By: simonmar Subscribers: duog, carter, simonmar, rwbarton, thomie GHC Trac Issues: #13604 Differential Revision: https://phabricator.haskell.org/D4123
-
open() can sometimes take a long time, for example on NFS or FUSE filesystems. We recently had a case where open() was taking multiple seconds to return for a (presumably overloaded) FUSE filesystem, which blocked GC and caused severe issues. Test Plan: validate Reviewers: niteria, bgamari, nh2, hvr, erikd Reviewed By: bgamari Subscribers: rwbarton, thomie, carter GHC Trac Issues: #13296 Differential Revision: https://phabricator.haskell.org/D4239
-
This was presumably a vestige of the days when the profiled RTS couldn't run threaded. Fixes #14545. Test Plan: simonmar Reviewers: erikd, simonmar Reviewed By: simonmar Subscribers: rwbarton, thomie, carter GHC Trac Issues: #14545 Differential Revision: https://phabricator.haskell.org/D4245
-
There appears to be no benefit in inlining this function. If you turn up the unfolding threshold a lot then it eventually inlines which produces a bit unoptimisable program. Reviewers: hvr, bgamari Reviewed By: bgamari Subscribers: rwbarton, thomie, carter Differential Revision: https://phabricator.haskell.org/D4246
-
Andreas Klebinger authored
This information was present in the ghc wiki but not the user guide. [skip ci] Test Plan: None Reviewers: bgamari Reviewed By: bgamari Subscribers: RyanGlScott, rwbarton, thomie, carter Differential Revision: https://phabricator.haskell.org/D4250
-
This fixes Issue #12372: documentation for Control.Monad.guard not useful after AMP. Reviewers: hvr, bgamari Reviewed By: bgamari Subscribers: rwbarton, thomie, carter Differential Revision: https://phabricator.haskell.org/D4258
-
-
Gabor Greif authored
Because in recent RHEL7 suddenly locales like `bokmål` pop up, which screw up reading-in of ASCII strings a line later. This additional criterion reliably eliminates those unicode characters.
-
Simon Peyton Jones authored
This patch fixes two bugs in the treatment of SigTvs at the kind level: - We should always generalise them, never default them (Trac #14555, #14563) - We should check if they get unified with each other (Trac #11203) Both are described in TcHsType Note [Kind generalisation and SigTvs]
-