rust/src/test/ui/generator
bors b18b9edf00 Auto merge of #52681 - pnkfelix:z-borrowck-migrate, r=nikomatsakis
Add `-Z borrowck=migrate`

This adds `-Z borrowck=migrate`, which represents the way we want to migrate to NLL under Rust versions to come. It also hooks this new mode into `--edition 2018`, which means we're officially turning NLL on in the 2018 edition.

The basic idea of `-Z borrowck=migrate` that there are cases where NLL is fixing old soundness bugs in the borrow-checker, but in order to avoid just breaking code by immediately rejecting the programs that hit those soundness bugs, we instead use the following strategy:

If your code is accepted by NLL, then we accept it.
If your code is rejected by both NLL and the old AST-borrowck, then we reject it.
If your code is rejected by NLL but accepted by the old AST-borrowck, then we emit the new NLL errors as **warnings**.

These warnings will be turned into hard errors in the future, and they say so in these diagnostics.

Fix #46908
2018-07-27 09:10:07 +00:00
..
auto-trait-regions.rs Adds support for immovable generators. Move checking of invalid borrows across suspension points to borrowck. Fixes #44197, #45259 and #45093. 2018-01-23 05:10:38 +01:00
auto-trait-regions.stderr use subtyping when we create a closure instead of for upvar types 2018-03-21 05:40:59 -04:00
borrowing.nll.stderr Don't match on region kinds when reporting NLL errors 2018-07-23 20:54:09 +01:00
borrowing.rs Update ui/generator tests to reflect changes from new generator drop rules. 2018-05-01 22:28:54 +02:00
borrowing.stderr Make resuming generators unsafe instead of the creation of immovable generators. Fixes #47787 2018-03-21 00:09:58 +01:00
dropck.nll.stderr Don't match on region kinds when reporting NLL errors 2018-07-23 20:54:09 +01:00
dropck.rs rust-lang/rust#51025: improve test robustness so that they work under NLL too. 2018-05-25 13:00:51 +02:00
dropck.stderr Update ui/generator tests to reflect changes from new generator drop rules. 2018-05-01 22:28:54 +02:00
generator-with-nll.rs integrate the edition code. 2018-07-26 14:51:32 +02:00
generator-with-nll.stderr integrate the edition code. 2018-07-26 14:51:32 +02:00
issue-48048.rs Fix visitation order of calls so that it matches execution order. Fixes #48048 2018-02-09 10:49:24 +01:00
issue-48048.stderr update tests 2018-03-14 00:53:24 +01:00
no-arguments-on-generators.rs Initial pass review comments 2017-08-09 13:56:19 -07:00
no-arguments-on-generators.stderr update tests 2018-03-14 00:53:24 +01:00
not-send-sync.rs Reword E0044 and message for !Send types 2018-03-14 18:04:20 -07:00
not-send-sync.stderr Auto merge of #48138 - estebank:issue-45092, r=nikomatsakis 2018-03-15 13:16:09 +00:00
pattern-borrow.rs rust-lang/rust#51025: improve test robustness so that they work under NLL too. 2018-05-25 13:00:51 +02:00
pattern-borrow.stderr update tests 2018-03-14 00:53:24 +01:00
ref-escapes-but-not-over-yield.nll.stderr Don't match on region kinds when reporting NLL errors 2018-07-23 20:54:09 +01:00
ref-escapes-but-not-over-yield.rs Point at var in short lived borrows 2017-12-14 22:45:45 -08:00
ref-escapes-but-not-over-yield.stderr update tests 2018-03-14 00:53:24 +01:00
sized-yield.rs Fix typo in error message E0277 2018-07-10 23:10:13 +02:00
sized-yield.stderr Fix doc link 2018-07-17 14:10:11 +02:00
yield-in-args.nll.stderr Checkpoint the current status of NLL on ui tests via compare-mode=nll. 2018-04-11 00:38:35 +02:00
yield-in-args.rs Fix tidy errors 2017-07-28 15:46:27 +02:00
yield-in-args.stderr update tests 2018-03-14 00:53:24 +01:00
yield-in-const.rs Add empty main() to tests where it is missing. 2018-03-14 12:23:28 -07:00
yield-in-const.stderr Add empty main() to tests where it is missing. 2018-03-14 12:23:28 -07:00
yield-in-function.rs Initial pass review comments 2017-08-09 13:56:19 -07:00
yield-in-function.stderr update tests 2018-03-14 00:53:24 +01:00
yield-in-static.rs Add empty main() to tests where it is missing. 2018-03-14 12:23:28 -07:00
yield-in-static.stderr Add empty main() to tests where it is missing. 2018-03-14 12:23:28 -07:00
yield-while-iterating.nll.stderr Access individual fields of tuples, closures and generators on drop. 2018-04-27 20:41:30 +01:00
yield-while-iterating.rs Make resuming generators unsafe instead of the creation of immovable generators. Fixes #47787 2018-03-21 00:09:58 +01:00
yield-while-iterating.stderr update tests 2018-03-14 00:53:24 +01:00
yield-while-local-borrowed.rs Make resuming generators unsafe instead of the creation of immovable generators. Fixes #47787 2018-03-21 00:09:58 +01:00
yield-while-local-borrowed.stderr update tests 2018-03-14 00:53:24 +01:00
yield-while-ref-reborrowed.nll.stderr Checkpoint the current status of NLL on ui tests via compare-mode=nll. 2018-04-11 00:38:35 +02:00
yield-while-ref-reborrowed.rs Make resuming generators unsafe instead of the creation of immovable generators. Fixes #47787 2018-03-21 00:09:58 +01:00
yield-while-ref-reborrowed.stderr update tests 2018-03-14 00:53:24 +01:00