summaryrefslogtreecommitdiff
path: root/testsuite/driver/extra_files.py
Commit message (Collapse)AuthorAgeFilesLines
* tests: remove extra_files.py (#12223)Reid Barton2017-02-261-523/+0
| | | | | | | | | | | | The script I used is included as testsuite/driver/kill_extra_files.py, though at this point it is for mostly historical interest. Some of the tests in libraries/hpc relied on extra_files.py, so this commit includes an update to that submodule. One test in libraries/process also relies on extra_files.py, but we cannot update that submodule so easily, so for now we special-case it in the test driver.
* tests: manually move some extra_files into *.T filesReid Barton2017-02-261-25/+0
| | | | | Some of the *.T files were in libraries/hpc, so this contains an update to that submodule.
* Remove extra_files entries for deleted testsReid Barton2017-02-261-15/+0
|
* Manually move extra_files for tests T9579_*Reid Barton2017-02-261-8/+0
| | | | | | | | | | | | Summary: My script won't understand this. Test Plan: validate Reviewers: austin, bgamari, simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D3210
* Fix recompilation tracking on signatures.Edward Z. Yang2017-02-171-0/+1
| | | | | | | | | | | | | | | | | | Summary: Previously we weren't tracking these dependencies at all, because we couldn't "find" the interface for {A.H}. Now we've associated hole names to the correct module identity so we will pick them up. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: bgamari, austin Subscribers: thomie, snowleopard Differential Revision: https://phabricator.haskell.org/D3131
* Fix a Backpack recompilation avoidance bug when signatures change.Edward Z. Yang2017-02-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Recompilation avoidance checks if -this-unit-id has changed by relying on the "wanted module" check in readIface ("Something is amiss..."). Unfortunately, this check didn't check if the instantiation made sense, which meant that if you changed the signatures of a Backpack package, we'd still treat the old signatures as up-to-date. The way I fixed this was by having findAndReadIface take in a 'Module' representing the /actual/ module we were intending to lookup. We convert this into the 'Module' we expect to see in 'mi_module' and now do a more elaborate check that will also verify that instantiations make sense. Along the way, I robustified the logging infrastructure for recompilation checking, and folded wrongIfaceModErr (which was dead code) into the error message. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: bgamari, austin Subscribers: thomie, snowleopard Differential Revision: https://phabricator.haskell.org/D3130
* Implement HasField constraint solving and modify OverloadedLabelsAdam Gundry2017-02-141-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This implements automatic constraint solving for the new HasField class and modifies the existing OverloadedLabels extension, as described in the GHC proposal (https://github.com/ghc-proposals/ghc-proposals/pull/6). Per the current form of the proposal, it does *not* currently introduce a separate `OverloadedRecordFields` extension. This replaces D1687. The users guide documentation still needs to be written, but I'll do that after the implementation is merged, in case there are further design changes. Test Plan: new and modified tests in overloadedrecflds Reviewers: simonpj, goldfire, dfeuer, bgamari, austin, hvr Reviewed By: bgamari Subscribers: maninalift, dfeuer, ysangkok, thomie, mpickering Differential Revision: https://phabricator.haskell.org/D2708
* Make type import/export API Annotation friendlyAlan Zimmerman2017-01-261-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: At the moment an export of the form type C(..) is parsed by the rule ``` | 'type' oqtycon {% amms (mkTypeImpExp (sLL $1 $> (unLoc $2))) [mj AnnType $1,mj AnnVal $2] } ``` This means that the origiinal oqtycon loses its location which is then retained in the AnnVal annotation. The problem is if the oqtycon has its own annotations, these get lost. e.g. in type (?)(..) the parens annotations for (?) get lost. This patch adds a wrapper around the name in the IE type to (a) provide a distinct location for the adornment annotation and (b) identify the specific adornment, for use in the pretty printer rather than occName magic. Updates haddock submodule Test Plan: ./validate Reviewers: mpickering, dfeuer, bgamari, austin Reviewed By: dfeuer Subscribers: dfeuer, thomie, mpickering Differential Revision: https://phabricator.haskell.org/D3016 GHC Trac Issues: #13163
* Always use -Xlinker for -rpathBartosz Nitka2017-01-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Currently we use `-Wl` which takes a list of comma-separated options. Unfortunately that breaks when you use it with `-rpath` and a path that has commas in them. Buck, the build system, produces paths with commas in them. `-Xlinker` doesn't have this disadvantage and as far as I can tell is supported by both `gcc` and `clang`. Anecdotally `nvcc` supports `-Xlinker`, but not `-Wl`. Test Plan: ./validate, harbourmaster Reviewers: nomeata, simonmar, austin, bgamari, hvr Reviewed By: simonmar, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2971
* Fix API Annotations for unboxed sumsAlan Zimmerman2017-01-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | An unboxed tuple such as (# | b | | | | | #) Ends up in the parser via `tup_exprs` as Sum 2 7 lexp where `lexp` is a `LHsExpr` From an API annotation perspective, the 5 `AnnVbar`s after the `b` were attached to `lexp`, but the leading `AnnVbar`s did not have a home. This patch attaches them all to the the parent tuple expression. The first (alt - 1) of them come before `lexp`, and the remaining (arity - alt) come after. Test Plan: ./validate Reviewers: osa1, austin, bgamari Subscribers: thomie, mpickering Differential Revision: https://phabricator.haskell.org/D2968 GHC Trac Issues: #12417
* Support for abi-depends for computing shadowing.Edward Z. Yang2016-12-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This is a complete fix based off of ed7af26606b3a605a4511065ca1a43b1c0f3b51d for handling shadowing and out-of-order -package-db flags simultaneously. The general strategy is we first put all databases together, overriding packages as necessary. Once this is done, we successfully prune out broken packages, including packages which depend on a package whose ABI differs from the ABI we need. Our check gracefully degrades in the absence of abi-depends, as we only check deps which are recorded in abi-depends. Contains time and Cabal submodule update. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: niteria, austin, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2846 GHC Trac Issues: #12485
* Check family instance consistency of hs-boot families later, fixes #11062.Edward Z. Yang2016-12-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | Summary: With hs-boot files, some type families may be defined in the module we are typechecking. In this case, we are not allowed to poke these families until after we typecheck our local declarations. So we first check everything involving non-recursive families, and then check the recursive families as we finish kind-checking them. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: goldfire, austin, simonpj, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2859 GHC Trac Issues: #11062
* Fix recompilation detection when set of signatures to merge changes.Edward Z. Yang2016-12-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | | Summary: Previously, we only checked to recompile if a signature we previously depended on changed; however, if the -unit-id settings changed, this could have resulted in more or less signatures needing to be merged in; we weren't checking for this case. (Note that this logic is irrelevant for normal module imports, which we also check using -unit-id, as we record each import and redo it, forcing a recompile if the result changed.) Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, austin, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2832
* Test for type synonym loops on TyCon.Edward Z. Yang2016-11-161-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Previously, we tested for type synonym loops by doing a syntactic test on the literal type synonym declarations. However, in some cases, loops could go through hs-boot files, leading to an infinite loop (#12042); a similar situation can occur when signature merging. This commit replaces the syntactic test with a test on TyCon, simply by walking down all type synonyms until we bottom out, or find we've looped back. It's a lot simpler. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, austin, bgamari Subscribers: goldfire, thomie Differential Revision: https://phabricator.haskell.org/D2656 GHC Trac Issues: #12042
* Fix -fobject-code with -fexternal-interpreterSimon Marlow2016-11-161-0/+1
| | | | | If the user does :cd in GHCi with -fexternal-interpreter, then we can fail to find the object files.
* Compute export hash based on ALL transitive orphan modules.Edward Z. Yang2016-10-181-0/+1
| | | | | | | | | | | | | | | | | | | Previously we pruned out orphan modules from external packages but this was wrong. Fixes #12733 (which has more discussion.) Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, bgamari, austin Reviewed By: simonpj Subscribers: simonpj, thomie Differential Revision: https://phabricator.haskell.org/D2610 GHC Trac Issues: #12733
* Track dep_finsts in exports hash, as it affects downstream deps.Edward Z. Yang2016-10-171-0/+1
| | | | | | | | | | | | | | | | | | | | Summary: I also added some more comments about the orphan and family instance hashing business. Fixes #12723. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: bgamari, austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2607 GHC Trac Issues: #12723
* The Backpack patch.Edward Z. Yang2016-10-081-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch implements Backpack for GHC. It's a big patch but I've tried quite hard to keep things, by-in-large, self-contained. The user facing specification for Backpack can be found at: https://github.com/ezyang/ghc-proposals/blob/backpack/proposals/0000-backpack.rst A guide to the implementation can be found at: https://github.com/ezyang/ghc-proposals/blob/backpack-impl/proposals/0000-backpack-impl.rst Has a submodule update for Cabal, as well as a submodule update for filepath to handle more strict checking of cabal-version. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, austin, simonmar, bgamari, goldfire Subscribers: thomie, mpickering Differential Revision: https://phabricator.haskell.org/D1482
* Tc267, tests what happens if you forgot to knot-tie.Edward Z. Yang2016-10-081-0/+1
| | | | Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
* Implement deriving strategiesRyan Scott2016-09-301-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Allows users to explicitly request which approach to `deriving` to use via keywords, e.g., ``` newtype Foo = Foo Bar deriving Eq deriving stock Ord deriving newtype Show ``` Fixes #10598. Updates haddock submodule. Test Plan: ./validate Reviewers: hvr, kosmikus, goldfire, alanz, bgamari, simonpj, austin, erikd, simonmar Reviewed By: alanz, bgamari, simonpj Subscribers: thomie, mpickering, oerjan Differential Revision: https://phabricator.haskell.org/D2280 GHC Trac Issues: #10598
* test #12567: add new testcase with expected plugin behaviourGabor Greif2016-09-041-0/+1
|
* A failing testcase for T12485Bartosz Nitka2016-08-311-0/+1
| | | | | | | | | | | | Test Plan: it's just a testcase Reviewers: ezyang, simonmar, bgamari, austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2450 GHC Trac Issues: #12485
* We also need to retypecheck before when we do parallel make.Edward Z. Yang2016-08-211-0/+1
| | | | | | | | | | | | | | | | | | Summary: Kept this seperate from the previous patch for clarity. Comes with a test. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, austin, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2220 GHC Trac Issues: #12035
* Axe initIfaceTc, tie the knot through HPT (or if_rec_types).Edward Z. Yang2016-08-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: initIfaceTc was originally used to make sure when we typecheck an interface, it can find the TyThings for things it itself defined. However, in the case of retypecheckLoop, this wasn't necessary because we ALREADY tied the knot through the HPT. This commit removes initIfaceTc, instead relying on the HPT to tie the knot. genModDetails' caller needed to be modified to tie the knot, but there are not that many call-sites of typecheckIface so the change is quite reasonable. We also introduce a new 'initIfaceLoad', which does NOT set up 'if_rec_types'. It's used when we're typechecking old, up-to-date interfaces in, since we're never going to update the type environment. The full details are in Note [Knot-tying typecheckIface]. Displeasingly, we need a special case to handle DFuns in the case of tcHiBootIface, see Note [DFun knot-tying special case] for the gory details. I also added another test which tickles a bug in a buggy version of this patch (see "Why the seq?") Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, austin, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2349
* check that the number of parallel build is greater than 0Ruey-Lin Hsu2016-08-051-0/+1
| | | | | | | | | | | | | | Fixes #12062. Reviewers: bgamari, thomie, austin, simonmar Reviewed By: bgamari, thomie, simonmar Subscribers: simonmar, thomie Differential Revision: https://phabricator.haskell.org/D2415 GHC Trac Issues: #12062
* Add a new determinism testBartosz Nitka2016-06-301-0/+1
| | | | This is one of the testcases that I forgot to commit
* Testsuite: use ignore_stderr/stdout instead of ignore_outputThomas Miedema2016-06-291-0/+1
| | | | | | | | | | | | | | | | | The problem with ignore_output is that it hides errors for WAY=ghci. GHCi always returns with exit code 0 (unless it is broken itself). For example: ghci015 must have been failing with compile errors for years, but we didn't notice because all output was ignored. Therefore, replace all uses of ignore_output with either ignore_stderr or ignore_stdout. In some cases I opted for adding the expected output. Update submodule hpc and stm. Reviewed by: simonmar Differential Revision: https://phabricator.haskell.org/D2367
* Testsuite: simplify extra_file handlingThomas Miedema2016-06-281-15/+15
| | | | | | | | | Before, `extra_files(['.hpc/Main.mix'])` meant copy `Main.mix` to `<testdir>/.hpc/Main.mix`. This feature wasn't really necessary, so now it just means copy `Main.mix` to `<testdir>/Main.mix`. This simplifies the implementation. Some small other cleanups as well. -40 lines of code.
* Add some determinism testsBartosz Nitka2016-06-071-0/+10
| | | | | | | | These are the tests that I accumulated fixing real issues. Each test is a separate thing that was broken and they are relatively small. GHC Trac: #4012
* Desugar ApplicativeDo and RecDo deterministicallyBartosz Nitka2016-06-061-0/+1
| | | | | | | | | | | | | | | | | This fixes a problem described in Note [Deterministic ApplicativeDo and RecursiveDo desugaring]. Test Plan: ./validate + new testcase Reviewers: simonpj, bgamari, austin, simonmar Reviewed By: simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2287 GHC Trac Issues: #4012
* Testsuite: fix enum01/02/03 on Windows (#9399)Thomas Miedema2016-05-251-3/+3
|
* Make Arrow desugaring deterministicBartosz Nitka2016-05-241-0/+1
| | | | | | | | | | | | | | | | | | | This kills two instances of varSetElems that turned out to be nondeterministic. I've tried to untangle this before, but it's a bit hard with the fixDs in the middle. Fortunately I now have a test case that proves that we need determinism here. Test Plan: ./validate, new testcase Reviewers: simonpj, simonmar, austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2258 GHC Trac Issues: #4012
* Testsuite: run tests in /tmp after copying required filesThomas Miedema2016-05-171-0/+535
Major change to the testsuite driver. For each TEST: * create a directory `<testdir>` inside `/tmp`. * link/copy all source files that the test needs into `<testdir>`. * run the test inside `<testdir>`. * delete `<testdir>` Extra files are (temporarily) tracked in `testsuite/driver/extra_files.py`, but can also be specified using the `extra_files` setup function. Differential Revision: https://phabricator.haskell.org/D1187 Reviewed by: Rufflewind, bgamari Trac: #11980