Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate region inference logic from error handling better #67404

Merged
merged 2 commits into from
Dec 21, 2019

Conversation

mark-i-m
Copy link
Member

Split out from #67241

r? @matthewjasper

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 18, 2019
@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-7 of your PR failed (pretty log, raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
2019-12-18T18:49:34.0647450Z ##[command]git remote add origin https://github.com/rust-lang/rust
2019-12-18T18:49:34.0847815Z ##[command]git config gc.auto 0
2019-12-18T18:49:34.0920917Z ##[command]git config --get-all http.https://github.com/rust-lang/rust.extraheader
2019-12-18T18:49:34.0976819Z ##[command]git config --get-all http.proxy
2019-12-18T18:49:35.0243719Z ##[command]git -c http.extraheader="AUTHORIZATION: basic ***" fetch --force --tags --prune --progress --no-recurse-submodules --depth=2 origin +refs/heads/*:refs/remotes/origin/* +refs/pull/67404/merge:refs/remotes/pull/67404/merge
---
2019-12-18T18:55:06.1277805Z    Compiling serde_json v1.0.40
2019-12-18T18:55:06.7813251Z    Compiling tidy v0.1.0 (/checkout/src/tools/tidy)
2019-12-18T18:55:16.0068410Z     Finished release [optimized] target(s) in 1m 13s
2019-12-18T18:55:16.0155703Z tidy check
2019-12-18T18:55:16.8357954Z tidy error: /checkout/src/librustc_mir/borrow_check/region_infer/mod.rs:1596: TODO is deprecated; use FIXME
2019-12-18T18:55:16.8358123Z tidy error: /checkout/src/librustc_mir/borrow_check/region_infer/mod.rs:1597: TODO is deprecated; use FIXME
2019-12-18T18:55:16.8358410Z tidy error: /checkout/src/librustc_mir/borrow_check/region_infer/mod.rs:1639: TODO is deprecated; use FIXME
2019-12-18T18:55:18.3299595Z Found 485 error codes
2019-12-18T18:55:18.3299895Z Found 0 error codes with no tests
2019-12-18T18:55:18.3299969Z Done!
2019-12-18T18:55:18.3300010Z some tidy checks failed
2019-12-18T18:55:18.3300010Z some tidy checks failed
2019-12-18T18:55:18.3300038Z 
2019-12-18T18:55:18.3300063Z 
2019-12-18T18:55:18.3300874Z command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/tidy" "/checkout/src" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "--no-vendor"
2019-12-18T18:55:18.3300969Z 
2019-12-18T18:55:18.3300993Z 
2019-12-18T18:55:18.3306749Z failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test src/tools/tidy
2019-12-18T18:55:18.3306814Z Build completed unsuccessfully in 0:01:17
2019-12-18T18:55:18.3306814Z Build completed unsuccessfully in 0:01:17
2019-12-18T18:55:18.3354475Z == clock drift check ==
2019-12-18T18:55:18.3382896Z   local time: Wed Dec 18 18:55:18 UTC 2019
2019-12-18T18:55:18.6017409Z   network time: Wed, 18 Dec 2019 18:55:18 GMT
2019-12-18T18:55:18.6023144Z == end clock drift check ==
2019-12-18T18:55:19.9734533Z 
2019-12-18T18:55:19.9831044Z ##[error]Bash exited with code '1'.
2019-12-18T18:55:19.9862250Z ##[section]Starting: Checkout
2019-12-18T18:55:19.9864077Z ==============================================================================
2019-12-18T18:55:19.9864141Z Task         : Get sources
2019-12-18T18:55:19.9864182Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

Copy link
Contributor

@matthewjasper matthewjasper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r=me with comment addressed

src/librustc_mir/borrow_check/region_infer/mod.rs Outdated Show resolved Hide resolved
Co-Authored-By: matthewjasper <mjjasper1@gmail.com>
@mark-i-m
Copy link
Member Author

@matthewjasper Done :)

@matthewjasper
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Dec 20, 2019

📌 Commit 90ef197 has been approved by matthewjasper

@bors
Copy link
Contributor

bors commented Dec 20, 2019

🌲 The tree is currently closed for pull requests below priority 100, this pull request will be tested once the tree is reopened

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 20, 2019
Centril added a commit to Centril/rust that referenced this pull request Dec 20, 2019
Separate region inference logic from error handling better

Split out from rust-lang#67241

r? @matthewjasper
Centril added a commit to Centril/rust that referenced this pull request Dec 20, 2019
Separate region inference logic from error handling better

Split out from rust-lang#67241

r? @matthewjasper
bors added a commit that referenced this pull request Dec 21, 2019
Rollup of 6 pull requests

Successful merges:

 - #67130 (Const prop should finish propagation into user defined variables)
 - #67163 (Split up ptr/mod.rs in libcore...)
 - #67314 (Don't suppress move errors for union fields)
 - #67392 (Fix unresolved type span inside async object)
 - #67404 (Separate region inference logic from error handling better)
 - #67428 (`is_binding_pat`: use explicit match & include or-pats in grammar)

Failed merges:

r? @ghost
@bors bors merged commit 90ef197 into rust-lang:master Dec 21, 2019
@mark-i-m mark-i-m deleted the split-1 branch December 21, 2019 06:14
Centril added a commit to Centril/rust that referenced this pull request Dec 22, 2019
…=matthewjasper

Refactorings to borrowck region diagnostic reporting

This PR is a followup to rust-lang#66886 and rust-lang#67404

EDIT: updated

In this PR:  Clean up how errors are collected from NLL: introduce `borrow_check::diagnostics::RegionErrors` to collect errors. This is later passed to `MirBorrowckCtx::report_region_errors` after the `MirBorrowckCtx` is created. This will allow us to refactor away some of the extra context structs floating around (but we don't do it in this PR).  `borrow_check::region_infer` is now mostly free of diagnostic generating code. The signatures of most of the functions in `region_infer` lose somewhere between 4 and 7 arguments :)

Left for future (feedback appreciated):

- Merge `ErrorRegionCtx` with `MirBorrowckCtx`, as suggested by @matthewjasper in rust-lang#66886 (comment)
- Maybe move the contents of `borrow_check::nll` into `borrow_check` and remove the `nll` submodule altogether.
- Find a way to make `borrow_check::diagnostics::region_errors` less of a strange appendage to `RegionInferenceContext`. I'm not really sure how to do this yet. Ideas welcome.
Centril added a commit to Centril/rust that referenced this pull request Dec 22, 2019
…=matthewjasper

Refactorings to borrowck region diagnostic reporting

This PR is a followup to rust-lang#66886 and rust-lang#67404

EDIT: updated

In this PR:  Clean up how errors are collected from NLL: introduce `borrow_check::diagnostics::RegionErrors` to collect errors. This is later passed to `MirBorrowckCtx::report_region_errors` after the `MirBorrowckCtx` is created. This will allow us to refactor away some of the extra context structs floating around (but we don't do it in this PR).  `borrow_check::region_infer` is now mostly free of diagnostic generating code. The signatures of most of the functions in `region_infer` lose somewhere between 4 and 7 arguments :)

Left for future (feedback appreciated):

- Merge `ErrorRegionCtx` with `MirBorrowckCtx`, as suggested by @matthewjasper in rust-lang#66886 (comment)
- Maybe move the contents of `borrow_check::nll` into `borrow_check` and remove the `nll` submodule altogether.
- Find a way to make `borrow_check::diagnostics::region_errors` less of a strange appendage to `RegionInferenceContext`. I'm not really sure how to do this yet. Ideas welcome.
Centril added a commit to Centril/rust that referenced this pull request Dec 22, 2019
…=matthewjasper

Refactorings to borrowck region diagnostic reporting

This PR is a followup to rust-lang#66886 and rust-lang#67404

EDIT: updated

In this PR:  Clean up how errors are collected from NLL: introduce `borrow_check::diagnostics::RegionErrors` to collect errors. This is later passed to `MirBorrowckCtx::report_region_errors` after the `MirBorrowckCtx` is created. This will allow us to refactor away some of the extra context structs floating around (but we don't do it in this PR).  `borrow_check::region_infer` is now mostly free of diagnostic generating code. The signatures of most of the functions in `region_infer` lose somewhere between 4 and 7 arguments :)

Left for future (feedback appreciated):

- Merge `ErrorRegionCtx` with `MirBorrowckCtx`, as suggested by @matthewjasper in rust-lang#66886 (comment)
- Maybe move the contents of `borrow_check::nll` into `borrow_check` and remove the `nll` submodule altogether.
- Find a way to make `borrow_check::diagnostics::region_errors` less of a strange appendage to `RegionInferenceContext`. I'm not really sure how to do this yet. Ideas welcome.
Centril added a commit to Centril/rust that referenced this pull request Dec 22, 2019
…=matthewjasper

Refactorings to borrowck region diagnostic reporting

This PR is a followup to rust-lang#66886 and rust-lang#67404

EDIT: updated

In this PR:  Clean up how errors are collected from NLL: introduce `borrow_check::diagnostics::RegionErrors` to collect errors. This is later passed to `MirBorrowckCtx::report_region_errors` after the `MirBorrowckCtx` is created. This will allow us to refactor away some of the extra context structs floating around (but we don't do it in this PR).  `borrow_check::region_infer` is now mostly free of diagnostic generating code. The signatures of most of the functions in `region_infer` lose somewhere between 4 and 7 arguments :)

Left for future (feedback appreciated):

- Merge `ErrorRegionCtx` with `MirBorrowckCtx`, as suggested by @matthewjasper in rust-lang#66886 (comment)
- Maybe move the contents of `borrow_check::nll` into `borrow_check` and remove the `nll` submodule altogether.
- Find a way to make `borrow_check::diagnostics::region_errors` less of a strange appendage to `RegionInferenceContext`. I'm not really sure how to do this yet. Ideas welcome.
bors added a commit that referenced this pull request Dec 24, 2019
Refactorings to borrowck region diagnostic reporting

This PR is a followup to #66886 and #67404

EDIT: updated

In this PR:  Clean up how errors are collected from NLL: introduce `borrow_check::diagnostics::RegionErrors` to collect errors. This is later passed to `MirBorrowckCtx::report_region_errors` after the `MirBorrowckCtx` is created. This will allow us to refactor away some of the extra context structs floating around (but we don't do it in this PR).  `borrow_check::region_infer` is now mostly free of diagnostic generating code. The signatures of most of the functions in `region_infer` lose somewhere between 4 and 7 arguments :)

Left for future (feedback appreciated):

- Merge `ErrorRegionCtx` with `MirBorrowckCtx`, as suggested by @matthewjasper in #66886 (comment)
- Maybe move the contents of `borrow_check::nll` into `borrow_check` and remove the `nll` submodule altogether.
- Find a way to make `borrow_check::diagnostics::region_errors` less of a strange appendage to `RegionInferenceContext`. I'm not really sure how to do this yet. Ideas welcome.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants