summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* testsuite: Add haddock perf test output to gitignorewip/ignore-t-filesBen Gamari2019-06-101-0/+2
| | | | [skip ci]
* Print role annotations in TemplateHaskell brackets (#16718)Vladislav Zavialov2019-06-105-0/+18
|
* base: Mark CPUTime001 as fragileBen Gamari2019-06-101-1/+1
| | | | | | As noted in #16224, CPUTime001 has been quite problematic, reporting non-monotonic timestamps in CI. Unfortunately I've been unable to reproduce this locally.
* rts: Fix RetainerProfile early return with TREC_CHUNKDaniel Gröber2019-06-091-1/+1
| | | | | | | | When pop() returns with `*c == NULL` retainerProfile will immediately return. All other code paths is pop() continue with the next stackElement when this happens so it seems weird to me that TREC_CHUNK we would suddenly abort everything even though the stack might still have elements left to process.
* Remove CPP ensuring word size is 32 or 64 bits around Addr# <-> int# primopsJohn Ericson2019-06-091-2/+0
| | | | | | | | | | | It shouldn't be needed these days, and those primops are "highly deprecated" anyways. This fits with my plans because it removes one bit of target-dependence of the builtin primops, and this is the hardest part of GHC to make multi-target. CC @carter
* Comments only: document tcdDataCusk better.Richard Eisenberg2019-06-091-0/+5
|
* Hadrian: need CPP preprocessor dependencies #16660David Eichmann2019-06-091-0/+13
| | | | | | | Use the new -include-cpp-deps ghc option (#16521) when generating .dependencies files in hadrian. This is version gated as -include-cpp-deps is a relatively new option.
* testsuite: Add test for #16509Ben Gamari2019-06-093-0/+14
|
* Do not report error if Name in pragma is unboundnineonine2019-06-094-1/+14
|
* rts: Separate population of eventTypes from initial event generationBen Gamari2019-06-091-8/+17
| | | | | | Previously these two orthogonal concerns were both implemented in postHeaderEvents which made it difficult to send header events after RTS initialization.
* Add disable/enable commands to ghci debugger #2215Roland Senn2019-06-098-41/+214
| | | | | | | | | | | | | | | | | | | | This patch adds two new commands `:enable` and `:disable` to the GHCi debugger. Opposite to `:set stop <n> :continue` a breakpoint disabled with `:disable` will not loose its previously set stop command. A new field breakEnabled is added to the BreakLocation data structure to track the enable/disable state. When a breakpoint is disabled with a `:disable` command, the following happens: The corresponding BreakLocation data element is searched dictionary of the `breaks` field of the GHCiStateMonad. If the break point is found and not already in the disabled state, the breakpoint is removed from bytecode. The BreakLocation data structure is kept in the breaks list and the new breakEnabled field is set to false. The `:enable` command works similar. The breaks field in the GHCiStateMonad was changed from an association list to int `IntMap`.
* Fix #16517 by bumping the TcLevel for method sigsRichard Eisenberg2019-06-0916-89/+163
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were actually two bugs fixed here: 1. candidateQTyVarsOfType needs to be careful that it does not try to zap metavariables from an outer scope as "naughty" quantification candidates. This commit adds a simple check to avoid doing so. 2. We weren't bumping the TcLevel in kcHsKindSig, which was used only for class method sigs. This mistake led to the acceptance of class C a where meth :: forall k. Proxy (a :: k) -> () Note that k is *locally* quantified. This patch fixes the problem by using tcClassSigType, which correctly bumps the level. It's a bit inefficient because tcClassSigType does other work, too, but it would be tedious to repeat much of the code there with only a few changes. This version works well and is simple. And, while updating comments, etc., I noticed that tcRnType was missing a pushTcLevel, leading to #16767, which this patch also fixes, by bumping the level. In the refactoring here, I also use solveEqualities. This initially failed ghci/scripts/T15415, but that was fixed by teaching solveEqualities to respect -XPartialTypeSignatures. This patch also cleans up some Notes around error generation that came up in conversation. Test case: typecheck/should_fail/T16517, ghci/scripts/T16767
* Handle trailing path separator in package DB names (#16360)Kevin Buhr2019-06-096-2/+37
| | | | | | | | | | Package DB directories with trailing separator (provided via GHC_PACKAGE_PATH or via -package-db) resulted in incorrect calculation of ${pkgroot} substitution variable. Keep the trailing separator while resolving as directory or file, but remove it before dropping the last path component with takeDirectory. Closes #16360.
* Small refactorings in ExtractDocsSimon Jakobi2019-06-091-34/+31
|
* testsuite: Add test for #16514Ben Gamari2019-06-094-0/+68
|
* Introduce log1p and expm1 primopschessai2019-06-0912-13/+108
| | | | | Previously log and exp were primitives yet log1p and expm1 were FFI calls. Fix this non-uniformity.
* testsuite: Suppress ticks in T4918 outputBen Gamari2019-06-091-1/+3
| | | | | As noted in #16741, this test otherwise breaks when `base` is compiled with `-g`.
* hadrian: Properly partition options in sourceArgsMatthew Pickering2019-06-091-1/+4
| | | | | | | | | Previously if you build the `ghc` package then it would has the default opts and the library opts. This is different behaviour to make where the library opts are only reserved for things in the `libraries` subdirectory (I believe) Fixes #16716
* Explain that 'mappend' and '(<>)' should be the same [skip ci]Alexandre Baldé2019-06-091-0/+3
|
* gitlab-ci: Ensure that all commits on a branch are submodule-lintedBen Gamari2019-06-081-2/+2
| | | | | | | | | | The previous commit reworked things such that the submodule linter would only run on the head commit. However, the linter only checks the submodules which are touched by the commits it is asked to lint. Consequently it would be possible for a bad submodule to sneak through. Thankfully, we can use the handy CI_COMMIT_BEFORE_SHA attribute to find the base commit of the push.
* gitlab-ci: Fix submodule linting of commitsBen Gamari2019-06-081-8/+11
| | | | | There is no notion of a base commit when we aren't checking a merge request. Just check the HEAD commit.
* gitlab-ci: Disable shallow clonesBen Gamari2019-06-081-9/+5
| | | | | | | | | | | | | | | Previously we were passing `--unshallow` to `git fetch` in the linting rules to ensure that the base commit which we were linting with respect to was available. However, this breaks due to GitLab's re-use of working directories since `git fetch --unshallow` fails on a repository which is not currently shallow. Given that `git fetch --unshallow` circumvents the efficiencies provided by shallow clones anyways, let's just disable them entirely. There is no documented way to do disable shallow clones but on checking the GitLab implementation it seems that setting `GIT_DEPTH=0` should do the trick.
* Remove trailing whitespaceMatthew Pickering2019-06-087-11/+11
| | | | | | [skip ci] This should really be caught by the linters! (#16711)
* gitlab-ci: A few clarifying commentsBen Gamari2019-06-081-0/+3
|
* gitlab-ci: Fix submodule linterBen Gamari2019-06-081-0/+6
| | | | | The job script didn't even try to compute the base commit to lint with respect to.
* gitlab-ci: Use --unshallow when fetching for lintersBen Gamari2019-06-081-2/+6
| | | | | | | GitLab creates a shallow clone. However, this means that we may not have the base commit of an MR when linting, causing `git merge-base` to fail. Fix this by passing `--unshallow` to `git fetch`, ensuring that we have the entire history.
* Fix two lint failures in rts/linker/MachO.cMatthew Pickering2019-06-081-2/+2
|
* gitlab-ci: Don't run two submodule checking jobs on Marge jobsMatthew Pickering2019-06-081-0/+3
|
* gitlab-ci: Linters, don't allow to failMatthew Pickering2019-06-081-1/+0
| | | | | Ben disabled them in cd85f8a71bb56cff332560e1d571b3406789fb71 but didn't say how or why they were broken.
* gitlab-ci: Create index.html in documentation deploymentBen Gamari2019-06-071-0/+6
| | | | | Otherwise navigating to https://ghc.gitlab.haskell.org/ghc will result in a 404.
* Hadrian: use deb9 Docker images instead of deb8 for CI jobsAlp Mestanogullari2019-06-071-3/+3
| | | | | | | This should fix #16739, where we seem to be getting extra carets in a test's output because of the gcc that ships with the deb8 image, whule we're not observing those extra carets in the deb9-based (Make) jobs.
* base: Export FinalizersBen Gamari2019-06-071-0/+1
| | | | As requested in #16750.
* Pass preprocessor options to C compiler when building foreign C files (#16737)Zejun Wu2019-06-075-4/+54
|
* remove backticks from markup - it doesn't mean what I think it meanscode5hot2019-06-071-1/+1
|
* Used terminology from a paper. Added it as a reference.code5hot2019-06-071-3/+4
|
* Update Traversable.hs with a note about an intuitive lawcode5hot2019-06-071-1/+7
|
* llvm-targets: Add x86_64 android layoutMoritz Angermann2019-06-072-1/+2
|
* Fix isValidNatural: The BigNat in NatJ# must have at least 2 limbsSimon Jakobi2019-06-076-1/+20
| | | | | | Previously the `integer-gmp` variant of `isValidNatural` would fail to detect values `<= maxBound::Word` that were incorrectly encoded using the `NatJ#` constructor.
* Hadrian: Delete target symlink in createFileLinkUntrackedBen Gamari2019-06-071-1/+4
| | | | | Previously createFileLinkUntracked would fail if the symlink already existed.
* Preserve ShadowInfo when rewriting evidenceSimon Peyton Jones2019-06-073-21/+44
| | | | | | | | | | | | | | | When the canonicaliser rewrites evidence of a Wanted, it should preserve the ShadowInfo (ctev_nosh) field. That is, a WDerive should rewrite to WDerive, and WOnly to WOnly. Previously we were unconditionally making a WDeriv, thereby rewriting WOnly to WDeriv. This bit Nick Frisby (issue #16735) in the context of his plugin, but we don't have a compact test case. The fix is simple, but does involve a bit more plumbing, to pass the old ShadowInfo around, to use when building the new Wanted.
* Factor out 'getLibDir' / 'getBaseDir' into a new GHC.BaseDir ghc-boot moduleJohn Ericson2019-06-074-55/+68
| | | | | | | | | | | | | | ghc-pkg and ghc already both needed this. I figure it is better to deduplicate, especially seeing that changes to one (FreeBSD CPP) didn't make it to the other. Additionally in !1090 I make ghc-pkg look up the settings file, which makes it use the top dir a bit more widely. If that lands, any difference in the way they find the top dir would be more noticable. That change also means sharing more code between ghc and ghc-package (namely the settings file parsing code), so I'd think it better to get off the slipperly slope of duplicating code now.
* Fix #16700: Tiny errors in output of GHCi commands :forward and :infoRoland Senn2019-06-077-3/+23
| | | | | | `:info Coercible` now outputs the correct section number of the GHCi User's guide together with the secion title. `:forward x` gives the correct syntax hint.
* Add HEAP_PROF_SAMPLE_END event to mark end of samplesMatthew Pickering2019-06-077-0/+34
| | | | | | | This allows a user to observe how long a sampling period lasts so that the time taken can be removed from the profiling output. Fixes #16697
* TmOracle: Replace negative term equalities by refutable PmAltConsSebastian Graf2019-06-0715-550/+672
| | | | | | | | | | | | | | | | | | | | | | | | | The `PmExprEq` business was a huge hack and was at the same time vastly too powerful and not powerful enough to encode negative term equalities, i.e. facts of the form "forall y. x ≁ Just y". This patch introduces the concept of 'refutable shapes': What matters for the pattern match checker is being able to encode knowledge of the kind "x can no longer be the literal 5". We encode this knowledge in a `PmRefutEnv`, mapping a set of newly introduced `PmAltCon`s (which are just `PmLit`s at the moment) to each variable denoting above inequalities. So, say we have `x ≁ 42 ∈ refuts` in the term oracle context and try to solve an equality like `x ~ 42`. The entry in the refutable environment will immediately lead to a contradiction. This machinery renders the whole `PmExprEq` and `ComplexEq` business unnecessary, getting rid of a lot of (mostly dead) code. See the Note [Refutable shapes] in TmOracle for a place to start. Metric Decrease: T11195
* [skip ci] Improve the documentation of the CNF primops. In this context, the ↵Andrew Martin2019-06-071-23/+40
| | | | term "size" is ambiguous and is now avoided. Additionally, the distinction between a CNF and the blocks that comprise it has been emphasize. The vocabulary has been made more consistent with the vocabulary in the C source for CNF.
* gitlab-ci: Disable darwin hadrian jobMatthew Pickering2019-06-071-1/+2
| | | | | | | | See #16771 We don't have enough capacity for the two jobs currently. [skip ci]
* Hadrian: profiling and debug enabled ways support -eventlog tooAlp Mestanogullari2019-06-041-1/+3
|
* make: Fix bindist installationBen Gamari2019-06-042-6/+5
| | | | | This fixes a few vestigial references to `settings` left over from !655. Fixes #16715.
* gitlab-ci: Run bindisttest during CIBen Gamari2019-06-041-0/+3
|
* Add GHCi :instances commandXavier Denis2019-06-0412-6/+314
| | | | | | | | | | | This commit adds the `:instances` command to ghci following proosal number 41. This makes it possible to query which instances are available to a given type. The output of this command is all the possible instances with type variables and constraints instantiated.