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

rustc: Add a warning count upon completion #69926

Merged
merged 1 commit into from
Apr 12, 2020
Merged

Conversation

roccodev
Copy link
Contributor

@roccodev roccodev commented Mar 11, 2020

This adds a build completed with one warning/x warnings message, similar to the already present aborted due to previous error message.

@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @estebank (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Mar 11, 2020
Copy link
Contributor

@estebank estebank left a comment

Choose a reason for hiding this comment

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

I feel these should only be emitted if the error count isn't.

For the test you need to run ./x.py test src/test/ui --stage 1 --bless (you can add --keep-stage 1 after the first time you do that) to update the .stderr files.

Comment on lines 831 to 837
self.emit_stashed_diagnostics();
let s = match self.deduplicated_warn_count {
0 => return,
1 => "build completed with one warning".to_string(),
count => format!("build completed with {} warnings", count),
};
let _ = self.emit_diagnostic(&Diagnostic::new(Level::Warning, &s));
Copy link
Contributor

Choose a reason for hiding this comment

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

Can't this logic go inside of print_error_count?

We could even get fancy and emit aborting due to XX previous errors, YY warnings emitted.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed, that could work.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

What would be your preferred way to print it if the build succeeds, but warnings are emitted?
I was thinking about leaving it as it is (warning: build completed with x warnings or something similar).

@estebank
Copy link
Contributor

Could you squash and rebase onto latest master running ./x.py test src/test/ui --bless and ./x.py test src/test/ui-fulldeps --bless? This will need to be merged on its own without a rollup because it will accrue merge conflicts quickly. Sorry about it, it will take a couple of tries most likely.

@bors rollup=never

@estebank
Copy link
Contributor

@bors r+ rollup=never

@bors
Copy link
Contributor

bors commented Mar 27, 2020

📌 Commit 6c1f21da58bdcd1171c26e007d264ae1894eaa45 has been approved by estebank

@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 Mar 27, 2020
@estebank
Copy link
Contributor

CC @rust-lang/compiler adding a count for warnings

0 => return,
let warnings = match self.deduplicated_warn_count {
0 => String::new(),
1 => "one warning emitted".to_string(),
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
1 => "one warning emitted".to_string(),
1 => "1 warning emitted".to_string(),

@@ -15,6 +15,6 @@ LL | #![plugin(empty_plugin)]
|
= note: `#[warn(deprecated)]` on by default

error: aborting due to previous error
error: aborting due to previous error, one warning emitted
Copy link
Member

Choose a reason for hiding this comment

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

It seems better just to stick with the usual warning, rather than merge it into the error message. The compilation isn't aborting due to the warning at all.

Copy link
Contributor

Choose a reason for hiding this comment

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

True, but that unnecessary wastes vertical space, which I. keep hearing complaints about.

Copy link
Member

Choose a reason for hiding this comment

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

Maybe we could have error: aborting due to previous error (1 warning emitted) or error: aborting due to previous error; 1 warning emitted instead, then. A comma seems inappropriate here.

@estebank
Copy link
Contributor

@bors r-

@roccodev could you address the suggested wording change to use a number 1 instead of the word one?

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Mar 27, 2020
@roccodev
Copy link
Contributor Author

Sure, what about the change @varkor was talking about regarding errors?

@estebank
Copy link
Contributor

The ; proposal sounds good to me.

@roccodev
Copy link
Contributor Author

Waiting on the build. I've also rebased everything onto the most recent changes to master.

@varkor
Copy link
Member

varkor commented Mar 27, 2020

Could you also squash the stderr changes together? (So that there is either one, or two commits: the code change, and the stderr changes.) This helps keep the git commit cleaner, which is convenient when using git blame. Thanks!

@varkor
Copy link
Member

varkor commented Mar 28, 2020

Thanks @roccodev!

@bors r=estebank,varkor rollup=never

@bors
Copy link
Contributor

bors commented Mar 28, 2020

📌 Commit 9f594d2bb0c11d7515dfcf34f7647d041594fa51 has been approved by estebank,varkor

@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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Mar 28, 2020
@bors
Copy link
Contributor

bors commented Mar 28, 2020

⌛ Testing commit 9f594d2bb0c11d7515dfcf34f7647d041594fa51 with merge d8564429444a927c3d361f296908dec8e34d3d55...

@bors
Copy link
Contributor

bors commented Mar 28, 2020

💔 Test failed - checks-azure

@Dylan-DPC-zz
Copy link

@bors p=1

@bors
Copy link
Contributor

bors commented Apr 11, 2020

⌛ Testing commit 2d8a8e2 with merge ba1f7570741b6069079a6e059bf395963fdbb119...

@bors
Copy link
Contributor

bors commented Apr 11, 2020

💔 Test failed - checks-azure

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 11, 2020
@roccodev
Copy link
Contributor Author

Failure:

failures:
    [ui (nll)] ui/hrtb/hrtb-perfect-forwarding.rs

test result: FAILED. 9793 passed; 1 failed; 90 ignored; 0 measured; 0 filtered out

I tried to --bless this test but nothing happens (tried with stage 0, 1 and 2), is this coming from another crate (even though the file is there)? Do I update it manually?

@varkor
Copy link
Member

varkor commented Apr 11, 2020

@roccodev: ah, I think you need to include the --compare-mode=nll flag when you --bless.

@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.
2020-04-11T12:35:33.5162220Z ========================== Starting Command Output ===========================
2020-04-11T12:35:33.5164619Z [command]/bin/bash --noprofile --norc /home/vsts/work/_temp/243516e3-86b1-4f56-850a-fc0790d0e223.sh
2020-04-11T12:35:33.5164930Z 
2020-04-11T12:35:33.5169292Z ##[section]Finishing: Disable git automatic line ending conversion
2020-04-11T12:35:33.5188778Z ##[section]Starting: Checkout rust-lang/rust@refs/pull/69926/merge to s
2020-04-11T12:35:33.5191756Z Task         : Get sources
2020-04-11T12:35:33.5191986Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.
2020-04-11T12:35:33.5192210Z Version      : 1.0.0
2020-04-11T12:35:33.5192368Z Author       : Microsoft
---
2020-04-11T12:35:36.2260568Z ##[command]git remote add origin https://github.com/rust-lang/rust
2020-04-11T12:35:36.2450147Z ##[command]git config gc.auto 0
2020-04-11T12:35:36.2480254Z ##[command]git config --get-all http.https://github.com/rust-lang/rust.extraheader
2020-04-11T12:35:36.2505470Z ##[command]git config --get-all http.proxy
2020-04-11T12:35:36.2579398Z ##[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/69926/merge:refs/remotes/pull/69926/merge
---
2020-04-11T12:39:15.4464109Z Looks like docker image is the same as before, not uploading
2020-04-11T12:39:21.0669118Z [CI_JOB_NAME=x86_64-gnu-llvm-7]
2020-04-11T12:39:21.0898012Z [CI_JOB_NAME=x86_64-gnu-llvm-7]
2020-04-11T12:39:21.0925574Z == clock drift check ==
2020-04-11T12:39:21.0932318Z   local time: Sat Apr 11 12:39:21 UTC 2020
2020-04-11T12:39:21.6527077Z   network time: Sat, 11 Apr 2020 12:39:21 GMT
2020-04-11T12:39:21.6553414Z Starting sccache server...
2020-04-11T12:39:21.7302492Z configure: processing command line
2020-04-11T12:39:21.7303029Z configure: 
2020-04-11T12:39:21.7303864Z configure: rust.dist-src        := False
---
2020-04-11T12:43:44.3326405Z    Compiling rustc_feature v0.0.0 (/checkout/src/librustc_feature)
2020-04-11T12:43:45.4423884Z    Compiling fmt_macros v0.0.0 (/checkout/src/libfmt_macros)
2020-04-11T12:43:46.6716221Z    Compiling rustc_ast_pretty v0.0.0 (/checkout/src/librustc_ast_pretty)
2020-04-11T12:43:47.4366107Z    Compiling rustc_hir v0.0.0 (/checkout/src/librustc_hir)
2020-04-11T12:43:54.2551175Z    Compiling rustc_query_system v0.0.0 (/checkout/src/librustc_query_system)
2020-04-11T12:43:56.1068268Z    Compiling rustc_hir_pretty v0.0.0 (/checkout/src/librustc_hir_pretty)
2020-04-11T12:43:59.5580138Z    Compiling rustc_attr v0.0.0 (/checkout/src/librustc_attr)
2020-04-11T12:44:02.8615439Z    Compiling rustc_parse v0.0.0 (/checkout/src/librustc_parse)
2020-04-11T12:44:10.1059797Z    Compiling rustc_ast_lowering v0.0.0 (/checkout/src/librustc_ast_lowering)
---
2020-04-11T13:02:00.7582408Z    Compiling rustc_feature v0.0.0 (/checkout/src/librustc_feature)
2020-04-11T13:02:02.2338116Z    Compiling fmt_macros v0.0.0 (/checkout/src/libfmt_macros)
2020-04-11T13:02:03.8940092Z    Compiling rustc_ast_pretty v0.0.0 (/checkout/src/librustc_ast_pretty)
2020-04-11T13:02:05.0750261Z    Compiling rustc_hir v0.0.0 (/checkout/src/librustc_hir)
2020-04-11T13:02:13.9852437Z    Compiling rustc_query_system v0.0.0 (/checkout/src/librustc_query_system)
2020-04-11T13:02:15.8382782Z    Compiling rustc_hir_pretty v0.0.0 (/checkout/src/librustc_hir_pretty)
2020-04-11T13:02:20.0187287Z    Compiling rustc_attr v0.0.0 (/checkout/src/librustc_attr)
2020-04-11T13:02:24.4388950Z    Compiling rustc_parse v0.0.0 (/checkout/src/librustc_parse)
2020-04-11T13:02:33.6918348Z    Compiling rustc_ast_lowering v0.0.0 (/checkout/src/librustc_ast_lowering)
---
2020-04-11T13:23:09.6678981Z .................................................................................................... 1700/9886
2020-04-11T13:23:13.1815912Z .................................................................................................... 1800/9886
2020-04-11T13:23:20.4406001Z .................................................................................................... 1900/9886
2020-04-11T13:23:27.1600256Z ....i............................................................................................... 2000/9886
2020-04-11T13:23:32.3642271Z ..............................................................................................iiiii. 2100/9886
2020-04-11T13:23:49.2874085Z .................................................................................................... 2300/9886
2020-04-11T13:23:51.1443803Z .................................................................................................... 2400/9886
2020-04-11T13:23:53.0127693Z .................................................................................................... 2500/9886
2020-04-11T13:23:57.7269111Z .................................................................................................... 2600/9886
---
2020-04-11T13:26:30.0366603Z .................................................................................................... 5100/9886
2020-04-11T13:26:36.2415587Z .................................................................................................... 5200/9886
2020-04-11T13:26:40.6024058Z .............i...................................................................................... 5300/9886
2020-04-11T13:26:48.7065466Z .................................................................................................... 5400/9886
2020-04-11T13:26:52.9864367Z ..ii.ii........i...i................................................................................ 5500/9886
2020-04-11T13:26:59.4532778Z ...............................................i.................................................... 5700/9886
2020-04-11T13:27:07.9951068Z ...................................................................ii............................... 5800/9886
2020-04-11T13:27:13.5458775Z ......i............................................................................................. 5900/9886
2020-04-11T13:27:18.5486601Z .................................................................................................... 6000/9886
2020-04-11T13:27:18.5486601Z .................................................................................................... 6000/9886
2020-04-11T13:27:26.8524018Z .................................................................................................... 6100/9886
2020-04-11T13:27:36.5861416Z ii...i..ii...........i.............................................................................. 6200/9886
2020-04-11T13:27:47.0542325Z .................................................................................................... 6400/9886
2020-04-11T13:27:49.9006938Z .................................................................................................... 6500/9886
2020-04-11T13:27:49.9006938Z .................................................................................................... 6500/9886
2020-04-11T13:27:59.9626249Z ..............................i..ii................................................................. 6600/9886
2020-04-11T13:28:19.1471565Z .................................................................................................... 6800/9886
2020-04-11T13:28:21.0149497Z ..............................i..................................................................... 6900/9886
2020-04-11T13:28:22.9515457Z .................................................................................................... 7000/9886
2020-04-11T13:28:24.9682817Z .....................................................................i.............................. 7100/9886
---
2020-04-11T13:29:44.4608172Z .................................................................................................... 7800/9886
2020-04-11T13:29:47.7065970Z .................................................................................................... 7900/9886
2020-04-11T13:29:52.9838288Z .................................................................................................... 8000/9886
2020-04-11T13:29:58.5293585Z ..................................i................................................................. 8100/9886
2020-04-11T13:30:06.0713134Z ..................................................................................iiiiii.iiiii.i.... 8200/9886
2020-04-11T13:30:18.9231755Z ............................i......i................................................................ 8400/9886
2020-04-11T13:30:21.6998956Z .................................................................................................... 8500/9886
2020-04-11T13:30:30.9402560Z .................................................................................................... 8600/9886
2020-04-11T13:30:41.2458852Z .................................................................................................... 8700/9886
---
2020-04-11T13:32:17.5805162Z 95    |
2020-04-11T13:32:17.5805426Z 96    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5805664Z 97 
2020-04-11T13:32:17.5805944Z - error: aborting due to 7 previous errors
2020-04-11T13:32:17.5806176Z + error: aborting due to 7 previous errors; 4 warnings emitted
2020-04-11T13:32:17.5806654Z 100 For more information about this error, try `rustc --explain E0133`.
2020-04-11T13:32:17.5807016Z 101 
2020-04-11T13:32:17.5807102Z 
2020-04-11T13:32:17.5807181Z 
2020-04-11T13:32:17.5807181Z 
2020-04-11T13:32:17.5807348Z The actual stderr differed from the expected stderr.
2020-04-11T13:32:17.5807955Z Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/binding/issue-53114-safety-checks/issue-53114-safety-checks.stderr
2020-04-11T13:32:17.5808917Z To update references, rerun the tests and pass the `--bless` flag
2020-04-11T13:32:17.5809602Z To only update this specific test, also pass `--test-args binding/issue-53114-safety-checks.rs`
2020-04-11T13:32:17.5810033Z error: 1 errors occurred comparing output.
2020-04-11T13:32:17.5810253Z status: exit code: 1
2020-04-11T13:32:17.5810253Z status: exit code: 1
2020-04-11T13:32:17.5812355Z command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/binding/issue-53114-safety-checks.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-Zdeduplicate-diagnostics=no" "--emit" "metadata" "-C" "prefer-dynamic" "--out-dir" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/binding/issue-53114-safety-checks" "-A" "unused" "-Crpath" "-O" "-Cdebuginfo=0" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/binding/issue-53114-safety-checks/auxiliary"
2020-04-11T13:32:17.5814422Z ------------------------------------------
2020-04-11T13:32:17.5814597Z 
2020-04-11T13:32:17.5814977Z ------------------------------------------
2020-04-11T13:32:17.5815181Z stderr:
2020-04-11T13:32:17.5815181Z stderr:
2020-04-11T13:32:17.5815554Z ------------------------------------------
2020-04-11T13:32:17.5815910Z warning: borrow of packed field is unsafe and requires unsafe function or block (error E0133)
2020-04-11T13:32:17.5816558Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:23:13
2020-04-11T13:32:17.5816824Z    |
2020-04-11T13:32:17.5817040Z LL |     let _ = &p.b;  //~ WARN    E0133
2020-04-11T13:32:17.5817428Z    |
2020-04-11T13:32:17.5817428Z    |
2020-04-11T13:32:17.5817656Z    = note: `#[warn(safe_packed_borrows)]` on by default
2020-04-11T13:32:17.5818132Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5819018Z    = note: for more information, see issue #46043 <***/issues/46043>
2020-04-11T13:32:17.5819584Z    = note: fields of packed structs might be misaligned: dereferencing a misaligned pointer or even just creating a misaligned reference is undefined behavior
2020-04-11T13:32:17.5820248Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5820876Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:26:13
2020-04-11T13:32:17.5821138Z    |
2020-04-11T13:32:17.5821138Z    |
2020-04-11T13:32:17.5821338Z LL |     let _ = &u2.a; //~ ERROR  [E0133]
2020-04-11T13:32:17.5821624Z    |             ^^^^^ access to union field
2020-04-11T13:32:17.5822162Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5822493Z 
2020-04-11T13:32:17.5822778Z warning: borrow of packed field is unsafe and requires unsafe function or block (error E0133)
2020-04-11T13:32:17.5823401Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:29:17
2020-04-11T13:32:17.5823401Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:29:17
2020-04-11T13:32:17.5823828Z    |
2020-04-11T13:32:17.5824038Z LL |     let (_,) = (&p.b,);  //~ WARN     E0133
2020-04-11T13:32:17.5824614Z    |
2020-04-11T13:32:17.5824991Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5824991Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5825768Z    = note: for more information, see issue #46043 <***/issues/46043>
2020-04-11T13:32:17.5826328Z    = note: fields of packed structs might be misaligned: dereferencing a misaligned pointer or even just creating a misaligned reference is undefined behavior
2020-04-11T13:32:17.5826991Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5833453Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:31:17
2020-04-11T13:32:17.5833771Z    |
2020-04-11T13:32:17.5833771Z    |
2020-04-11T13:32:17.5833987Z LL |     let (_,) = (u1.a,);  //~ ERROR   [E0133]
2020-04-11T13:32:17.5834417Z    |                 ^^^^ access to union field
2020-04-11T13:32:17.5834969Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5835284Z 
2020-04-11T13:32:17.5835570Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5836353Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:32:17
2020-04-11T13:32:17.5836353Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:32:17
2020-04-11T13:32:17.5836616Z    |
2020-04-11T13:32:17.5836844Z LL |     let (_,) = (&u2.a,); //~ ERROR   [E0133]
2020-04-11T13:32:17.5837132Z    |                 ^^^^^ access to union field
2020-04-11T13:32:17.5837689Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5838004Z 
2020-04-11T13:32:17.5838285Z warning: borrow of packed field is unsafe and requires unsafe function or block (error E0133)
2020-04-11T13:32:17.5839219Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:39:11
2020-04-11T13:32:17.5839219Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:39:11
2020-04-11T13:32:17.5839484Z    |
2020-04-11T13:32:17.5840001Z LL |     match &p.b  { _ => { } } //~ WARN     E0133
2020-04-11T13:32:17.5840424Z    |
2020-04-11T13:32:17.5840787Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5840787Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5841651Z    = note: for more information, see issue #46043 <***/issues/46043>
2020-04-11T13:32:17.5842195Z    = note: fields of packed structs might be misaligned: dereferencing a misaligned pointer or even just creating a misaligned reference is undefined behavior
2020-04-11T13:32:17.5842877Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5843501Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:41:11
2020-04-11T13:32:17.5843763Z    |
2020-04-11T13:32:17.5843763Z    |
2020-04-11T13:32:17.5844004Z LL |     match u1.a  { _ => { } } //~ ERROR   [E0133]
2020-04-11T13:32:17.5844289Z    |           ^^^^ access to union field
2020-04-11T13:32:17.5844819Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5845146Z 
2020-04-11T13:32:17.5845416Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5846024Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:42:11
2020-04-11T13:32:17.5846024Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:42:11
2020-04-11T13:32:17.5846305Z    |
2020-04-11T13:32:17.5846524Z LL |     match &u2.a { _ => { } } //~ ERROR   [E0133]
2020-04-11T13:32:17.5846810Z    |           ^^^^^ access to union field
2020-04-11T13:32:17.5847359Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5847673Z 
2020-04-11T13:32:17.5847973Z warning: borrow of packed field is unsafe and requires unsafe function or block (error E0133)
2020-04-11T13:32:17.5848787Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:45:12
2020-04-11T13:32:17.5848787Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:45:12
2020-04-11T13:32:17.5849061Z    |
2020-04-11T13:32:17.5849310Z LL |     match (&p.b,)  { (_,) => { } } //~ WARN     E0133
2020-04-11T13:32:17.5849722Z    |
2020-04-11T13:32:17.5850083Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5850083Z    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
2020-04-11T13:32:17.5850919Z    = note: for more information, see issue #46043 <***/issues/46043>
2020-04-11T13:32:17.5851464Z    = note: fields of packed structs might be misaligned: dereferencing a misaligned pointer or even just creating a misaligned reference is undefined behavior
2020-04-11T13:32:17.5852343Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5852923Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:47:12
2020-04-11T13:32:17.5853232Z    |
2020-04-11T13:32:17.5853232Z    |
2020-04-11T13:32:17.5853738Z LL |     match (u1.a,)  { (_,) => { } } //~ ERROR   [E0133]
2020-04-11T13:32:17.5853979Z    |            ^^^^ access to union field
2020-04-11T13:32:17.5854420Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5854669Z 
2020-04-11T13:32:17.5855003Z error[E0133]: access to union field is unsafe and requires unsafe function or block
2020-04-11T13:32:17.5855460Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:48:12
2020-04-11T13:32:17.5855460Z   --> /checkout/src/test/ui/binding/issue-53114-safety-checks.rs:48:12
2020-04-11T13:32:17.5855642Z    |
2020-04-11T13:32:17.5855801Z LL |     match (&u2.a,) { (_,) => { } } //~ ERROR   [E0133]
2020-04-11T13:32:17.5856024Z    |            ^^^^^ access to union field
2020-04-11T13:32:17.5856397Z    = note: the field may not be properly initialized: using uninitialized data will cause undefined behavior
2020-04-11T13:32:17.5856627Z 
2020-04-11T13:32:17.5856627Z 
2020-04-11T13:32:17.5856786Z error: aborting due to 7 previous errors; 4 warnings emitted
2020-04-11T13:32:17.5857233Z For more information about this error, try `rustc --explain E0133`.
2020-04-11T13:32:17.5857400Z 
2020-04-11T13:32:17.5857653Z ------------------------------------------
2020-04-11T13:32:17.5857773Z 
---
2020-04-11T13:32:17.5859355Z thread 'main' panicked at 'Some tests failed', src/tools/compiletest/src/main.rs:348:22
2020-04-11T13:32:17.5859644Z note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
2020-04-11T13:32:17.5867060Z 
2020-04-11T13:32:17.5867192Z 
2020-04-11T13:32:17.5870956Z command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/compiletest" "--compile-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" "--run-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" "--rustc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "--src-base" "/checkout/src/test/ui" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "ui" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-7/bin/FileCheck" "--nodejs" "/usr/bin/node" "--host-rustcflags" "-Crpath -O -Cdebuginfo=0 -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--target-rustcflags" "-Crpath -O -Cdebuginfo=0 -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--docck-python" "/usr/bin/python2.7" "--lldb-python" "/usr/bin/python2.7" "--gdb" "/usr/bin/gdb" "--quiet" "--llvm-version" "7.0.0" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
2020-04-11T13:32:17.5874130Z 
2020-04-11T13:32:17.5874232Z 
2020-04-11T13:32:17.5874829Z failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test --exclude src/tools/tidy
2020-04-11T13:32:17.5875204Z Build completed unsuccessfully in 0:51:34
2020-04-11T13:32:17.5875204Z Build completed unsuccessfully in 0:51:34
2020-04-11T13:32:17.5927738Z == clock drift check ==
2020-04-11T13:32:17.5943873Z   local time: Sat Apr 11 13:32:17 UTC 2020
2020-04-11T13:32:17.6632938Z   network time: Sat, 11 Apr 2020 13:32:17 GMT
2020-04-11T13:32:18.5602888Z 
2020-04-11T13:32:18.5602888Z 
2020-04-11T13:32:18.5658504Z ##[error]Bash exited with code '1'.
2020-04-11T13:32:18.5671946Z ##[section]Finishing: Run build
2020-04-11T13:32:18.5721099Z ##[section]Starting: Checkout rust-lang/rust@refs/pull/69926/merge to s
2020-04-11T13:32:18.5726240Z Task         : Get sources
2020-04-11T13:32:18.5726587Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.
2020-04-11T13:32:18.5726909Z Version      : 1.0.0
2020-04-11T13:32:18.5727149Z Author       : Microsoft
2020-04-11T13:32:18.5727149Z Author       : Microsoft
2020-04-11T13:32:18.5727505Z Help         : [More Information](https://go.microsoft.com/fwlink/?LinkId=798199)
2020-04-11T13:32:18.5727918Z ==============================================================================
2020-04-11T13:32:18.8413348Z Cleaning any cached credential from repository: rust-lang/rust (GitHub)
2020-04-11T13:32:18.8473020Z ##[section]Finishing: Checkout rust-lang/rust@refs/pull/69926/merge to s
2020-04-11T13:32:18.8554075Z Cleaning up task key
2020-04-11T13:32:18.8555227Z Start cleaning up orphan processes.
2020-04-11T13:32:18.8710402Z Terminate orphan process: pid (6537) (python)
2020-04-11T13:32:18.9255355Z ##[section]Finishing: Finalize Job

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 @rust-lang/infra. (Feature Requests)

@roccodev
Copy link
Contributor Author

Some tests were introduced today/yesterday; --blessing them as I write.

@varkor
Copy link
Member

varkor commented Apr 11, 2020

@bors r=estebank,varkor rollup=never

@bors
Copy link
Contributor

bors commented Apr 11, 2020

📌 Commit b85c64c has been approved by estebank,varkor

@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 Apr 11, 2020
@bors
Copy link
Contributor

bors commented Apr 12, 2020

⌛ Testing commit b85c64c with merge 941d435...

@bors
Copy link
Contributor

bors commented Apr 12, 2020

☀️ Test successful - checks-azure
Approved by: estebank,varkor
Pushing 941d435 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Apr 12, 2020
@bors bors merged commit 941d435 into rust-lang:master Apr 12, 2020
@rust-highfive
Copy link
Collaborator

📣 Toolstate changed by #69926!

Tested on commit 941d435.
Direct link to PR: #69926

💔 rls on linux: test-pass → test-fail (cc @Xanewok).

rust-highfive added a commit to rust-lang-nursery/rust-toolstate that referenced this pull request Apr 12, 2020
Tested on commit rust-lang/rust@941d435.
Direct link to PR: <rust-lang/rust#69926>

💔 rls on linux: test-pass → test-fail (cc @Xanewok).
bors added a commit to rust-lang/cargo that referenced this pull request Apr 13, 2020
Fix nightly test matching rustc "warning" output.

rust-lang/rust#69926 changed the warning output from rustc.  #8080 attempted to compensate for it, but missed one of the cases.  I don't think this test needs to be quite so exhaustive about checking the output.
Mark-Simulacrum pushed a commit to rust-lang/cargo that referenced this pull request May 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. 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.

8 participants