ah thanks for the ping
Ah, I had no idea about
#[rustc_error] - I'll need to remember that in future.
that's good, because i just added a note asking you to use it on #52793. :)
(you shouldn't need to add an explicit use of NLL to the test, since
compare-mode=nll will take care of that.)
An alternative approach would be to use the
revisions: system to encode all the various variants that one might want to test (AST-borrowck, NLL, 2008 edition migration mode, ...). But that is more effort than is probably warranted in this case.
I wasn't sure if revisions was supported in
yeah they are
The interaction with
compare-mode=nll can sometimes be tricky
but it basically ends up being something where you can have R*2 stderr files, where R is the number of revisions
file.rev1.err, file.rev2.err, ..., file.revN.err, file.rev1.nll.err, file.rev2.nll.err, ..., file.revN.nll.err
but we don't encounter that often
and I actually added a way to opt out of compare-mode
in order to sidestep a nasty case where the revisions I wanted to encode were meant to inject their own
-Z borrowck flag usage
You can see it in this test case here: https://github.com/pnkfelix/rust/blob/9f05f29e564c03a432df78f7c4b6421e4fb1a338/src/test/ui/borrowck/borrowck-migrate-to-nll.rs#L22
anyway, you really dont have to use revisions in this case. Its simpler and just as effective to let
compare-mode=nll do the work.
@pnkfelix test should be updated now.
oh great that was a lot quicker than I expected
@pnkfelix added the comment.
There may be an extra "output" word in there, but it might just still make sense.