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

Report const eval error inside the query #53821

Open
wants to merge 21 commits into
base: master
from

Conversation

@oli-obk
Contributor

oli-obk commented Aug 30, 2018

Functional changes: We no longer warn about bad constants embedded in unused types. This relied on being able to report just a warning, not a hard error on that case, which we cannot do any more now that error reporting is consistently centralized.

r? @RalfJung

fixes #53561

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Aug 30, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:22:11]    Compiling serialize v0.0.0 (file:///checkout/src/libserialize)
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ieee.rs:741:21
[00:22:11]     |
[00:22:11] 741 |                     self = Self::NAN;
[00:22:11]     |                     ^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ieee.rs:809:53
[00:22:11]     |
[00:22:11]     |
[00:22:11] 809 |             (Category::Infinity, Category::Zero) => Status::INVALID_OP.and(Self::NAN),
[00:22:11]     |                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ieee.rs:971:49
[00:22:11]     |
[00:22:11]     |
[00:22:11] 971 |             (Category::Zero, Category::Zero) => Status::INVALID_OP.and(Self::NAN),
[00:22:11]     |                                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1021:36
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1021 |             (_, Category::Zero) => Status::INVALID_OP.and(Self::NAN),
[00:22:11]      |                                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1100:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1100 |                 Status::OK.and(Self::SMALLEST)
[00:22:11]      |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1093:44
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1093 |                     Status::INVALID_OP.and(Self::NAN.copy_sign(self))
[00:22:11]      |                                            ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1105:43
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1105 |                     return Status::OK.and(-Self::ZERO);
[00:22:11]      |                                           ^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1110:28
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1110 |                     return Status::OK.and(Self::INFINITY);
[00:22:11]      |                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1203:45
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1203 |             "inf" | "INFINITY" => return Ok(Status::OK.and(Self::INFINITY)),
[00:22:11]      |                                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1204:62
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1204 |             "-inf" | "-INFINITY" => return Ok(Status::OK.and(-Self::INFINITY)),
[00:22:11]      |                                                              ^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1205:40
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1205 |             "nan" | "NaN" => return Ok(Status::OK.and(Self::NAN)),
[00:22:11]      |                                        ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1206:57
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1206 |             "-nan" | "-NaN" => return Ok(Status::OK.and(-Self::NAN)),
[00:22:11]      |                                                         ^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1554:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1554 |                 (Status::OVERFLOW | Status::INEXACT).and(Self::INFINITY)
[00:22:11]      |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1810:31
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1810 |             None => return Ok(Status::OK.and(Self::ZERO)),
[00:22:11]      |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1913:31
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1913 |             None => return Ok(Status::OK.and(Self::ZERO)),
[00:22:11]      |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1953:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1953 |                 IeeeFloat::SMALLEST
[00:22:11]      |                 ^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1955:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1955 |                 IeeeFloat::ZERO
[00:22:11]      |                 ^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:637:5
[00:22:11]     |
[00:22:11] 637 |     const PRECISION: usize = S::PRECISION;
[00:22:11]     |                              |
[00:22:11]     |                              referenced constant has errors
[00:22:11]     |
[00:22:11]     = note: #[deny(const_err)] on by default
[00:22:11]     = note: #[deny(const_err)] on by default
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]   --> librustc_apfloat/ppc.rs:63:30
[00:22:11]    |
[00:22:11] 63 |     const PRECISION: usize = Fallback::<F>::PRECISION;
[00:22:11]    |                              ^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:637:5
[00:22:11]     |
[00:22:11] 637 |     const PRECISION: usize = S::PRECISION;
[00:22:11]     |                              |
[00:22:11]     |                              referenced constant has errors
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:147:30
[00:22:11]     |
[00:22:11] 147 |     const PRECISION: usize = Fallback::<F>::PRECISION;
[00:22:11]     |                              ^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:638:5
[00:22:11]     |
[00:22:11] 638 |     const MAX_EXP: ExpInt = S::MAX_EXP;
[00:22:11]     |                             |
[00:22:11]     |                             referenced constant has errors
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:148:29
[00:22:11]     |
[00:22:11] 148 |     const MAX_EXP: ExpInt = Fallback::<F>::MAX_EXP;
[00:22:11]     |                             ^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:639:5
[00:22:11]     |
[00:22:11] 639 |     const MIN_EXP: ExpInt = S::MIN_EXP;
[00:22:11]     |                             |
[00:22:11]     |                             referenced constant has errors
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:149:29
[00:22:11]     |
[00:22:11] 149 |     const MIN_EXP: ExpInt = Fallback::<F>::MIN_EXP;
[00:22:11]     |                             ^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:192:44
[00:22:11]     |
[00:22:11] 192 |                     Status::INVALID_OP.and(Self::NAN.copy_sign(self))
[00:22:11]     |                                            ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:301:53
[00:22:11]     |
[00:22:11] 301 |             (Category::Infinity, Category::Zero) => Status::OK.and(Self::NAN),
[00:22:11]     |                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error: aborting due to 27 previous errors
[00:22:11] 
[00:22:11] For more information about this error, try `rustc --explain E0080`.
[00:22:11] error: Could not compile `rustc_apfloat`.

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)

Collaborator

rust-highfive commented Aug 30, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:22:11]    Compiling serialize v0.0.0 (file:///checkout/src/libserialize)
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ieee.rs:741:21
[00:22:11]     |
[00:22:11] 741 |                     self = Self::NAN;
[00:22:11]     |                     ^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ieee.rs:809:53
[00:22:11]     |
[00:22:11]     |
[00:22:11] 809 |             (Category::Infinity, Category::Zero) => Status::INVALID_OP.and(Self::NAN),
[00:22:11]     |                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ieee.rs:971:49
[00:22:11]     |
[00:22:11]     |
[00:22:11] 971 |             (Category::Zero, Category::Zero) => Status::INVALID_OP.and(Self::NAN),
[00:22:11]     |                                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1021:36
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1021 |             (_, Category::Zero) => Status::INVALID_OP.and(Self::NAN),
[00:22:11]      |                                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1100:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1100 |                 Status::OK.and(Self::SMALLEST)
[00:22:11]      |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1093:44
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1093 |                     Status::INVALID_OP.and(Self::NAN.copy_sign(self))
[00:22:11]      |                                            ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1105:43
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1105 |                     return Status::OK.and(-Self::ZERO);
[00:22:11]      |                                           ^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1110:28
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1110 |                     return Status::OK.and(Self::INFINITY);
[00:22:11]      |                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1203:45
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1203 |             "inf" | "INFINITY" => return Ok(Status::OK.and(Self::INFINITY)),
[00:22:11]      |                                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1204:62
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1204 |             "-inf" | "-INFINITY" => return Ok(Status::OK.and(-Self::INFINITY)),
[00:22:11]      |                                                              ^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1205:40
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1205 |             "nan" | "NaN" => return Ok(Status::OK.and(Self::NAN)),
[00:22:11]      |                                        ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1206:57
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1206 |             "-nan" | "-NaN" => return Ok(Status::OK.and(-Self::NAN)),
[00:22:11]      |                                                         ^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1554:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1554 |                 (Status::OVERFLOW | Status::INEXACT).and(Self::INFINITY)
[00:22:11]      |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1810:31
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1810 |             None => return Ok(Status::OK.and(Self::ZERO)),
[00:22:11]      |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1913:31
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1913 |             None => return Ok(Status::OK.and(Self::ZERO)),
[00:22:11]      |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1953:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1953 |                 IeeeFloat::SMALLEST
[00:22:11]      |                 ^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]     --> librustc_apfloat/ieee.rs:1955:17
[00:22:11]      |
[00:22:11]      |
[00:22:11] 1955 |                 IeeeFloat::ZERO
[00:22:11]      |                 ^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:637:5
[00:22:11]     |
[00:22:11] 637 |     const PRECISION: usize = S::PRECISION;
[00:22:11]     |                              |
[00:22:11]     |                              referenced constant has errors
[00:22:11]     |
[00:22:11]     = note: #[deny(const_err)] on by default
[00:22:11]     = note: #[deny(const_err)] on by default
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]   --> librustc_apfloat/ppc.rs:63:30
[00:22:11]    |
[00:22:11] 63 |     const PRECISION: usize = Fallback::<F>::PRECISION;
[00:22:11]    |                              ^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:637:5
[00:22:11]     |
[00:22:11] 637 |     const PRECISION: usize = S::PRECISION;
[00:22:11]     |                              |
[00:22:11]     |                              referenced constant has errors
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:147:30
[00:22:11]     |
[00:22:11] 147 |     const PRECISION: usize = Fallback::<F>::PRECISION;
[00:22:11]     |                              ^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:638:5
[00:22:11]     |
[00:22:11] 638 |     const MAX_EXP: ExpInt = S::MAX_EXP;
[00:22:11]     |                             |
[00:22:11]     |                             referenced constant has errors
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:148:29
[00:22:11]     |
[00:22:11] 148 |     const MAX_EXP: ExpInt = Fallback::<F>::MAX_EXP;
[00:22:11]     |                             ^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] 
[00:22:11] error: any use of this value will cause an error
[00:22:11]    --> librustc_apfloat/ieee.rs:639:5
[00:22:11]     |
[00:22:11] 639 |     const MIN_EXP: ExpInt = S::MIN_EXP;
[00:22:11]     |                             |
[00:22:11]     |                             referenced constant has errors
[00:22:11] 
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:149:29
[00:22:11]     |
[00:22:11] 149 |     const MIN_EXP: ExpInt = Fallback::<F>::MIN_EXP;
[00:22:11]     |                             ^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:192:44
[00:22:11]     |
[00:22:11] 192 |                     Status::INVALID_OP.and(Self::NAN.copy_sign(self))
[00:22:11]     |                                            ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error[E0080]: erroneous constant used
[00:22:11] error[E0080]: erroneous constant used
[00:22:11]    --> librustc_apfloat/ppc.rs:301:53
[00:22:11]     |
[00:22:11] 301 |             (Category::Infinity, Category::Zero) => Status::OK.and(Self::NAN),
[00:22:11]     |                                                     ^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
[00:22:11] error: aborting due to 27 previous errors
[00:22:11] 
[00:22:11] For more information about this error, try `rustc --explain E0080`.
[00:22:11] error: Could not compile `rustc_apfloat`.

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)

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Aug 30, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:49:48] ....................................................................................................
[00:49:51] ....................................................................................................
[00:49:54] ............i.......................................................................................
[00:49:57] ....................................................................................................
[00:49:59] .............................................................iiiiiiiii..............................
[00:50:05] ....................................................................................................
[00:50:09] ....................................................................................................
[00:50:12] .........................................i..........................................................
[00:50:15] ...........................................................................................i.i..ii..
---
[00:57:10] ---- [run-pass-valgrind] run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary.rs stdout ----
[00:57:10] 
[00:57:10] error: compilation failed!
[00:57:10] status: exit code: 101
[00:57:10] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary.rs" "--target=x86_64-unknown-linux-gnu" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary/a" "-Crpath" "-O" "-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/run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary/auxiliary"
[00:57:10] ------------------------------------------
[00:57:10] 
[00:57:10] ------------------------------------------
[00:57:10] stderr:
[00:57:10] stderr:
[00:57:10] ------------------------------------------
[00:57:10] thread 'main' panicked at 'cannot alloc memory for unsized type', librustc_mir/interpret/place.rs:690:9
[00:57:10] 
[00:57:10] error: internal compiler error: unexpected panic
[00:57:10] 
[00:57:10] note: the compiler unexpectedly panicked. this is a bug.
[00:57:10] note: the compiler unexpectedly panicked. this is a bug.
[00:57:10] 
[00:57:10] note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports
[00:57:10] 
[00:57:10] note: rustc 1.30.0-dev running on x86_64-unknown-linux-gnu
[00:57:10] 
[00:57:10] note: compiler flags: -Z unstable-options -C prefer-dynamic -C rpath
[00:57:10] 
[00:57:10] ------------------------------------------
[00:57:10] 
[00:57:10] thread '[run-pass-valgrind] run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
---
[00:57:10] 
[00:57:10] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:57:10] 
[00:57:10] 
[00:57:10] 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/run-pass-valgrind" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-pass-valgrind" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "run-pass-valgrind" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-lThu, 30 Aug 2018 15:33:44 GMT

The command "date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
" exited with 0.
travis_fold:start:after_failure.1

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)

Collaborator

rust-highfive commented Aug 30, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:49:48] ....................................................................................................
[00:49:51] ....................................................................................................
[00:49:54] ............i.......................................................................................
[00:49:57] ....................................................................................................
[00:49:59] .............................................................iiiiiiiii..............................
[00:50:05] ....................................................................................................
[00:50:09] ....................................................................................................
[00:50:12] .........................................i..........................................................
[00:50:15] ...........................................................................................i.i..ii..
---
[00:57:10] ---- [run-pass-valgrind] run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary.rs stdout ----
[00:57:10] 
[00:57:10] error: compilation failed!
[00:57:10] status: exit code: 101
[00:57:10] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary.rs" "--target=x86_64-unknown-linux-gnu" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary/a" "-Crpath" "-O" "-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/run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary/auxiliary"
[00:57:10] ------------------------------------------
[00:57:10] 
[00:57:10] ------------------------------------------
[00:57:10] stderr:
[00:57:10] stderr:
[00:57:10] ------------------------------------------
[00:57:10] thread 'main' panicked at 'cannot alloc memory for unsized type', librustc_mir/interpret/place.rs:690:9
[00:57:10] 
[00:57:10] error: internal compiler error: unexpected panic
[00:57:10] 
[00:57:10] note: the compiler unexpectedly panicked. this is a bug.
[00:57:10] note: the compiler unexpectedly panicked. this is a bug.
[00:57:10] 
[00:57:10] note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports
[00:57:10] 
[00:57:10] note: rustc 1.30.0-dev running on x86_64-unknown-linux-gnu
[00:57:10] 
[00:57:10] note: compiler flags: -Z unstable-options -C prefer-dynamic -C rpath
[00:57:10] 
[00:57:10] ------------------------------------------
[00:57:10] 
[00:57:10] thread '[run-pass-valgrind] run-pass-valgrind/unsized-locals/long-live-the-unsized-temporary.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
---
[00:57:10] 
[00:57:10] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:57:10] 
[00:57:10] 
[00:57:10] 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/run-pass-valgrind" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-pass-valgrind" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "run-pass-valgrind" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-lThu, 30 Aug 2018 15:33:44 GMT

The command "date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
" exited with 0.
travis_fold:start:after_failure.1

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)

Show outdated Hide outdated src/librustc/hir/def.rs Outdated
@RalfJung

This comment has been minimized.

Show comment
Hide comment
@RalfJung

RalfJung Aug 30, 2018

Member

The part inside CTFE/miri looks good to me. I do not think I can adequately review the HIR changes though, so I'd prefer if you could get someone else to take a look at that.

There are a huge amount of changes to the ui test output -- some error messages got deduplicated, but many others (and many more, I think) got duplicated. Why is that? Can you avoid that?

Member

RalfJung commented Aug 30, 2018

The part inside CTFE/miri looks good to me. I do not think I can adequately review the HIR changes though, so I'd prefer if you could get someone else to take a look at that.

There are a huge amount of changes to the ui test output -- some error messages got deduplicated, but many others (and many more, I think) got duplicated. Why is that? Can you avoid that?

@bors

This comment was marked as outdated.

Show comment
Hide comment
@bors

bors Aug 31, 2018

Contributor

☔️ The latest upstream changes (presumably #53779) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Aug 31, 2018

☔️ The latest upstream changes (presumably #53779) made this pull request unmergeable. Please resolve the merge conflicts.

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Aug 31, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:52:06] ....................................................................................................
[00:52:09] ....................................................................................................
[00:52:12] ...............i....................................................................................
[00:52:15] ....................................................................................................
[00:52:17] ................................................................iiiiiiiii...........................
[00:52:23] ....................................................................................................
[00:52:26] ....................................................................................................
[00:52:29] ............................................i.......................................................
[00:52:32] ..............................................................................................i.i..i

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)

Collaborator

rust-highfive commented Aug 31, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:52:06] ....................................................................................................
[00:52:09] ....................................................................................................
[00:52:12] ...............i....................................................................................
[00:52:15] ....................................................................................................
[00:52:17] ................................................................iiiiiiiii...........................
[00:52:23] ....................................................................................................
[00:52:26] ....................................................................................................
[00:52:29] ............................................i.......................................................
[00:52:32] ..............................................................................................i.i..i

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)

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Aug 31, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:47:02] ....................................................................................................
[00:47:05] ....................................................................................................
[00:47:08] ...............i....................................................................................
[00:47:11] ....................................................................................................
[00:47:13] ................................................................iiiiiiiii...........................
[00:47:18] ....................................................................................................
[00:47:22] ....................................................................................................
[00:47:25] ............................................i.......................................................
[00:47:27] ..............................................................................................i.i..i

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)

Collaborator

rust-highfive commented Aug 31, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:47:02] ....................................................................................................
[00:47:05] ....................................................................................................
[00:47:08] ...............i....................................................................................
[00:47:11] ....................................................................................................
[00:47:13] ................................................................iiiiiiiii...........................
[00:47:18] ....................................................................................................
[00:47:22] ....................................................................................................
[00:47:25] ............................................i.......................................................
[00:47:27] ..............................................................................................i.i..i

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)

LL | bytes: [u8; std::mem::size_of::<Foo>()]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
= note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle
note: cycle used when processing `Foo`

This comment has been minimized.

@RalfJung

RalfJung Aug 31, 2018

Member

Is it expected that "requires const-evaluating + checking Foo::bytes::{{constant}}" occurs twice at the end of this cycle?

...which requires const-evaluating + checking Foo::bytes::{{constant}}...
...which again requires const-evaluating + checking Foo::bytes::{{constant}}, completing the cycle

@RalfJung

RalfJung Aug 31, 2018

Member

Is it expected that "requires const-evaluating + checking Foo::bytes::{{constant}}" occurs twice at the end of this cycle?

...which requires const-evaluating + checking Foo::bytes::{{constant}}...
...which again requires const-evaluating + checking Foo::bytes::{{constant}}, completing the cycle

@bors

This comment was marked as outdated.

Show comment
Hide comment
@bors

bors Sep 1, 2018

Contributor

☔️ The latest upstream changes (presumably #53604) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Sep 1, 2018

☔️ The latest upstream changes (presumably #53604) made this pull request unmergeable. Please resolve the merge conflicts.

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Sep 4, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:44:08] ....................................................................................................
[00:44:11] ....................................................................................................
[00:44:14] ....................................................................................................
[00:44:17] ........i...........................................................................................
[00:44:21] .......................F.........................F............F................................F....
[00:44:27] ............................ii..iii.................................................................
[00:44:30] ....................................................................................................
[00:44:32] ....................................................................................................
[00:44:34] ....................................................................................................
---
[00:44:52] ....................................................................................................
[00:44:55] ....................................................................................................
[00:44:58] ....................................................................................................
[00:45:01] ....................................................................................................
[00:45:04] .......................................................................F............................
[00:45:07] ......................................................................................F.............
[00:45:13] ....................................................................................................
[00:45:16] ..........................................................i.........................................
[00:45:19] ....................................................................................................
[00:45:22] ........i.i..ii.....................................................................................
---
[00:46:00] 
[00:46:00] ---- [ui] ui/consts/const-eval/const-pointer-values-in-various-types.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] - error[E0080]: this constant likely exhibits undefined behavior
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] 3    |
[00:46:00] 3    |
[00:46:00] 4 LL |     const I32_REF_USIZE_UNION: usize = unsafe { Nonsense { int_32_ref: &3 }.u };
[00:46:00] 6    |
[00:46:00] 6    |
[00:46:00] 7    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 11    |
[00:46:00] 11    |
[00:46:00] 12 LL |     const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };
[00:46:00] 16    |
[00:46:00] 17    = note: #[deny(const_err)] on by default
[00:46:00] 18 
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 21    |
[00:46:00] 21    |
[00:46:00] 22 LL |     const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };
[00:46:00] 24    |                                             |
[00:46:00] 24    |                                             |
[00:46:00] 25    |                                             a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 29    |
[00:46:00] 29    |
[00:46:00] 30 LL |     const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };
[00:46:00] 32    |                                             |
[00:46:00] 32    |                                             |
[00:46:00] 33    |                                             a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] 34 
[00:46:00] - error[E0080]: this constant likely exhibits undefined behavior
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] 37    |
[00:46:00] 37    |
[00:46:00] 38 LL |     const I32_REF_U64_UNION: u64 = unsafe { Nonsense { int_32_ref: &3 }.uint_64 };
[00:46:00] 40    |
[00:46:00] 40    |
[00:46:00] 41    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 45    |
[00:46:00] 45    |
[00:46:00] 46 LL |     const I32_REF_U128_UNION: u128 = unsafe { Nonsense { int_32_ref: &3 }.uint_128 };
[00:46:00] 47    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempted to read undefined bytes
[00:46:00] 48 
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 51    |
[00:46:00] 51    |
[00:46:00] 52 LL |     const I32_REF_I8_UNION: i8 = unsafe { Nonsense { int_32_ref: &3 }.int_8 };
[00:46:00] 54    |                                           |
[00:46:00] 54    |                                           |
[00:46:00] 55    |        en't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 105    |
[00:46:00] 105    |
[00:46:00] 106 LL |     const I32_REF_BOOL_UNION: bool = unsafe { Nonsense { int_32_ref: &3 }.truthy_falsey };
[00:46:00] 108    |                                               |
[00:46:00] 108    |                                               |
[00:46:00] 109    |                                               a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 113    |
[00:46:00] 113    |
[00:46:00] 114 LL |     const I32_REF_CHAR_UNION: char = unsafe { Nonsense { int_32_ref: &3 }.character };
[00:46:00] 116    |                                               |
[00:46:00] 116    |                                               |
[00:46:00] 117    |                                               a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 121    |
[00:46:00] 121    |
[00:46:00] 122 LL |     const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: "3" }.uint_8 };
[00:46:00] 
[00:46:00] 124    |                          :46:00] 173    |                                         a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 177    |
[00:46:00] 177    |
[00:46:00] 178 LL |     const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: "3" }.int_32 };
[00:46:00] 180    |                                         |
[00:46:00] 180    |                                         |
[00:46:00] 181    |                                         a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] 182 
[00:46:00] - error[E0080]: this constant likely exhibits undefined behavior
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] 185    |
[00:46:00] 185    |
[00:46:00] 186 LL |     const STR_I64_UNION: i64 = unsafe { Nonsense { stringy: "3" }.int_64 };
[00:46:00] 188    |
[00:46:00] 188    |
[00:46:00] 189    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 193    |
[00:46:00] 193    |
[00:46:00] 194 LL |     const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: "3" }.int_128 };
[00:46:00] 
[00:46:00] 196    |     " "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/const-pointer-values-in-various-types/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":382,"byte_end":458,"line_start":24,"line_end":24,"column_start":5,"column_end":81,"is_primary":true,"text":[{"text":"    const I32_REF_USIZE_UNION: usize = unsafe { Nonsense { int_32_ref: &3 }.u };","highlight_start":5,"highlight_end":81}],"label":"type validation failed: encountered a pointer, but expected the type usize","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:24:5\n   |\nLL |     const I32_REF_USIZE_UNION: usize = unsafe { Nonsense { int_32_ref: &3 }.u };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type usize\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":566,"byte_end":600,"line_start":27,"line_end":27,"column_start":43,"column_end":77,"is_primary":false,"text":[{"text":"    const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };","highlight_start":43,"highlight_end":77}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":528,"byte_end":603,"line_start":27,"line_end":27,"column_start":5,"column_end":80,"is_primary":true,"text":[{"text":"    const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };","highlight_start":5,"highlight_end":80}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"#[deny(const_err)] on by default","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:27:5\n   |\nLL |     const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^----------------------------------^^^\n   |                                           |\n   |                                           a raw memory access tried to access part of a pointer value as raw bytes\n   |\n   = note: #[deny(const_err)] on by default\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":693,"byte_end":728,"line_start":30,"line_end":30,"column_start":45,"column_end":80,"is_primary":false,"text":[{"text":"    const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };","highlight_start":45,"highlight_end":80}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":653,"byte_end":731,"line_start":30,"line_end":30,"column_start":5,"column_end":83,"is_primary":true,"text":[{"text":"    const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };","highlight_start":5,"highlight_end":83}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:30:5\n   |\nLL |     const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":821,"byte_end":856,"line_start":33,"line_end":33,"column_start":45,"column_end":80,"is_primary":false,"text":[{"text":"    const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };","highlight_start":45,"highlight_end":80}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":781,"byte_end":859,"line_start":33,"line_end":33,"column_start":5,"column_end":83,"is_primary":true,"text":[{"text":"    const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };","highlight_start":5,"highlight_end":83}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:33:5\n   |\nLL |     const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":909,"byte_end":987,"line_start":36,"line_end":36,"column_start":5,"column_end":83,"is_primary":true,"text":[{"text":"    const I32_REF_U64_UNION: u64 = unsafe { Nonsense { int_32_ref: &3 }.uint_64 };","highlight_start":5,"highlight_end":83}],"label":"type validation failed: encountered a pointer, but expected the type u64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:36:5\n   |\nLL |     const I32_REF_U64_UNION: u64 = unsafe { Nonsense { int_32_ref: &3 }.uint_64 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type u64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1057,"byte_end":1138,"line_start":39,"line_end":39,"column_start":5,"column_end":86,"is_primary":true,"text":[{"text":"    const I32_REF_U128_UNION: u128 = unsafe { Nonsense { int_32_ref: &3 }.uint_128 };","highlight_start":5,"highlight_end":86}],"label":"attempted to read undefined bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:39:5\n   |\nLL |     const I32_REF_U128_UNION: u128 = unsafe { Nonsense { int_32_ref: &3 }.uint_128 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempted to read undefined bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1226,"byte_end":1259,"line_start":42,"line_end":42,"column_start":43,"column_end":76,"is_primary":false,"text":[{"text":"    const I32_REF_I8_UNION: i8 = unsafe { Nonsense { int_32_ref: &3 }.int_8 };","highlight_start":43,"highlight_end":76}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1188,"byte_end":1262,"line_start":42,"line_end":42,"column_start":5,"columI32_REF_I32_UNION: i32 = unsafe { Nonsense { int_32_ref: &3 }.int_32 };","highlight_start":5,"highlight_end":82}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:48:5\n   |\nLL |     const I32_REF_I32_UNION: i32 = unsafe { Nonsense { int_32_ref: &3 }.int_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^----------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1566,"byte_end":1643,"line_start":51,"line_end":51,"column_start":5,"column_end":82,"is_primary":true,"text":[{"text":"    c:null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:57:5\n   |\nLL |     const I32_REF_F32_UNION: f32 = unsafe { Nonsense { int_32_ref: &3 }.float_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^------------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1972,"byte_end":2051,"line_start":60,"line_end":60,"column_start":5,"column_end":84,"is_primary":true,"text":[{"text":"    const I32_REF_F64_UNION: f64 = unsafe { Nonsense { int_32_ref: &3 }.float_64 };","highlight_start":5,"highlight_end":84}],"label":"type validation ied to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2257,"byte_end":2339,"line_start":66,"line_end":66,"column_start":5,"column_end":87,"is_primary":true,"text":[{"text":"    const I32_REF_CHAR_UNION: char = unsafe { Nonsense { int_32_ref: &3 }.character };","highlight_start":5,"highlight_end":87}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:66:5\n   |\nLL |     const I32_REF_CHAR_UNION: char = unsafe { Nonsense { int_32_ref: &3 }.character };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-------------------------------------^^^\n   |                                               |\n   |                                               a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2423,"byte_end":2455,"line_start":69,"line_end":69,"column_start":39,"column_end":71,"is_primary":false,"text":[{"text":"    const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: \"3\" }.uint_8 };","highlight_start":39,"highlight_end":71}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2389,"byte_end":2458,"line_start":69,"line_end":69,"column_start":5,"column_end":74,"is_primary":true,"text":[{"text":"    const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: \"3\" }.uint_8 };","highlight_start":5,"highlight_end":74}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:69:5\n   |\nLL |     const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: \"3\" }.uint_8 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------------------^^^\n   |                                       |\n   |                                       a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2544,"byte_end":2577,"line_start":72,"line_end":72,"column_start":41,"column_end":74,"is_primary":false,"text":[{"text":"    const STR_U16_UNION: u16 = unsafe { Nonsense { stringy: \"3\" }.uint_16 };","highlight_start":41,"highlight_end":74}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2508,"byte_end":2580,"line_start":72,"line_end":72,"column_start":5,"column_end":77,"is_primary":true,"text":[{"text":"    const STR_U16_UNION: u16 = unsafe { Nonsense { stringy: \"3\" }.uint_16 };","highlight_start":5,"highlight_end":77}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:72:5\n   |\nLL |     const STR_U16_UNION: u16 = unsafe { Nonsense { stringy: \"3\" }.uint_16 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^---------------------------------^^^\n   |                                         |\n   |                                         a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2666,"byte_end":2699,"line_start":75,"line_end":75,"column_start":41,"column_end":74,"is_primary":false,"text":[{"text":"    const STR_U32_UNION: u32 = unsafe { Nonsense { stringy: \"3\" }.uint_32 };","highlight_start":41,"highlight_end":74}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2752,"byte_end":2824,"line_start":78,"line_end":78,"column_start":5,"column_end":77,"is_primary":true,"text":[{"text":"    const STR_U64_UNION: u64 = unsafe { Nonsense { stringy: \"3\" }.uint_64 };","highlight_start":5,"highlight_end":77}],"label":"type validation failed: encountered a pointer, but expected the type u64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:78:5\n   |\nLL |     const STR_U64_UNION: u64 = unsafe { Nonsense { stringy: \"3\" }.uint_64 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type u64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2932,"byte_end":2966,"line_start":81,"line_end":81,"column_start":43,"column_end":77,"is_primary":false,"text":[{"text":"    const STR_U128_UNION: u128 = unsafe { Nonsense { stringy: \"3\" }.uint_128 };","highlight_start":43,"highlight_end":77}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2894,"byte_end":2969,"line_start":81,"line_end":81,"column_start":5,"column_end":80,"is_primary":true,"text":[{"text":"    const STR_U128_UNION: u128 = unsafe { Nonsense { stringy: \"3\" }.uint_128 };","highlight_start":5,"highlight_end":80}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:81:5\n   |\nLL |     const STR_U128_UNION: u128 = unsafe { Nonsense { stringy: \"3\" }.uint_128 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^----------------------------------^^^\n   |                                           |\n   |                                           a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-point5,"line_start":87,"line_end":87,"column_start":41,"column_end":73,"is_primary":false,"text":[{"text":"    const STR_I16_UNION: i16 = unsafe { Nonsense { stringy: \"3\" }.int_16 };","highlight_start":41,"highlight_end":73}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3137,"byte_end":3208,"line_start":87,"line_end":87,"column_start":5,"column_end":76,"is_primary":true,"text":[{"text":"    const STR_I16_UNION: i16 = unsafe { Nonsense { stringy: \"3\" }.int_16 };","highlight_start":5,"highlight_end":76}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:87:5\n   |\nLL |     const STR_I16_UNION: i16 = unsafe { Nonsense { stringy: \"3\" }.int_16 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------------------^^^\n   |                                         |\n   |                                         a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3294,"byte_end":3326,"line_start":90,"line_end":90,"column_start":41,"column_end":73,"is_primary":false,"text":[{"text":"    const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: \"3\" }.int_32 };","highlight_start":41,"highlight_end":73}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3258,"byte_end":3329,"line_start":90,"line_end":90,"column_start":5,"column_end":76,"is_primary":true,"text":[{"text":"    const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: \"3\" }.int_32 };","highlight_start":5,"highlight_end":76}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:90:5\n   |\nLL |     const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: \"3\" }.int_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------------------^^^\n   |                                         |\n   |                                         a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3379,"byte_end":3450,"line_start":93,"line_end":93,"column_start":5,"column_end":76,"is_primary":true,"text":[{"text":"    const STR_I64_UNION: i64 = unsafe { Nonsense { stringy: \"3\" }.int_64 };","highlight_start":5,"highlight_end":76}],"label":"type validation failed: encountered a pointer, but expected the type i64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:93:5\n   |\nLL |     const STR_I64_UNION: i64 = unsafe { Nonsense { stringy: \"3\" }.int_64 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type i64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3558,"byte_end":3591,"line_start":96,"line_end":96,"column_start":43,"column_end":76,"is_primary":false,"text":[{"text":"    const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: \"3\" }.int_128 };","highlight_start":43,"highlight_end":76}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3520,"byte_end":3594,"line_start":96,"line_end":96,"column_start":5,"column_end":79,"is_primary":true,"text":[{"text":"    const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: \"3\" }.int_128 };","highlight_start":5,"highlight_end":79}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:96:5\n   |\nLL |     const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: \"3\" }.int_128 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^---------------------------------^^^\n   |                                           |\n   |                      s tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3767,"byte_end":3840,"line_start":102,"line_end":102,"column_start":5,"column_end":78,"is_primary":true,"text":[{"text":"    const STR_F64_UNION: f64 = unsafe { Nonsense { stringy: \"3\" }.float_64 };","highlight_start":5,"highlight_end":78}],"label":"type validation failed: encountered a pointer, but expected the type f64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/snsion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:108:5\n   |\nLL |     const STR_CHAR_UNION: char = unsafe { Nonsense { stringy: \"3\" }.character };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------------------------------^^^\n   |                                           |\n   |                                           a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"aborting due to 29 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 29 previous errors\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0080`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0080`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/consts/const-eval/const-pointer-values-in-various-types.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:46:00] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:46:00] 
[00:46:00] ---- [ui] ui/consts/const-eval/issue-52442.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 4 LL |     [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type
[00:46:00] 6 
[00:46:00] - error: aborting due to previous error
[00:46:00] - error: aborting due to previous error
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] +   --> $DIR/issue-52442.rs:12:11
[00:46:00] +    |
[00:46:00] + LL |     [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type
[00:46:00] +    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type usize
[00:46:00] +    |
[00:46:00] +    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - For more information about this error, try `rustc --explain E0019`.
[00:46:00] + error: aborting due to 2 previous errors
[00:46:00] + 
[00:46:00] + Some errors occurred: E0019, E0080.
[00:46:00] + Some errors occurred: E0019, E0080.
[00:46:00] + For more information about an error, try `rustc --explain E0019`.
[00:46:00] 10 
[00:46:00] 
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/issue-52442/issue-52442.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args consts/const-eval/issue-52442.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-eval/issue-52442.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic"  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type","highlight_start":14,"highlight_end":28}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0019]: constant contains unimplemented expression type\n  --> /checkout/src/test/ui/consts/const-eval/issue-52442.rs:12:14\n   |\nLL |     [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type\n   |              ^^^^^^^^^^^^^^\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52442.rs","byte_start":489,"byte_end":529,"line_start":12,"line_end":12,"column_start":11,"column_end":51,"is_primary":true,"text":[{"text":"    [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type","highlight_start":11,"highlight_end":51}],"label":"type validation failed: encountered a pointer, but expected the type usize","suggested_replacement":0] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ref_to_int_match/ref_to_int_match.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args consts/const-eval/ref_to_int_match.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ref_to_int_match/a" "-Crpath" "-O" "-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/consts/const-eval/ref_to_int_match/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs","byte_start":829,"byte_end":874,"line_start":33,"line_end":33,"column_start":1,"column_end":46,"is_primary":true,"text":[{"text":"const BAR: Int = unsafe { Foo { r: &42 }.f };","highlight_start":1,"highlight_end":46}],"label":"type validation failed: encountered a pointer, but expected the type u64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs:33:1\n   |\nLL | const BAR: Int = unsafe { Foo { r: &42 }.f };\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type u64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"could not evaluate constant pattern","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs","byte_start":578,"byte_end":581,"line_start":17,"line_end":17,"column_start":14,"column_end":17,"is_primary":true,"text":[{"text":"        10..=BAR => {}, //~ ERROR lower range bound must be less than or equal to upper","highlight_start":14,"highlight_end":17}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: could not evaluate constant pattern\n  --> /checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs:17:14\n   |\nLL |         10..=BAR => {}, //~ ERROR lower range bound must be less than or equal to upper\n   |              ^^^\n\n"}
[00:46:00] {"message":"aborting due to 2 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 2 previous errors\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0080`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0080`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/consts/const-eval/ref_to_int_match.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] 
[00:46:00] 
[00:46:00] ---- [ui] ui/consts/const-size_of-cycle.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 1 error[E0391]: cycle de | ^^^^^^^^^^
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-size_of-cycle/const-size_of-cycle.stderr
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-size_of-cycle/const-size_of-cycle.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args consts/const-size_of-cycle.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-size_of-cycle.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-size_of-cycle/a" "-Crpath" "-O" "-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/consts/const-size_of-cycle/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] {"message":"cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-size_of-cycle.rs","byte_start":530,"byte_end":556,"line_start":14,"line_end":14,"column_start":17,"column_end":43,"is_primary":true,"text":[{"text":"    bytes: [u8; std::mem::size_of::<Foo>()]","highlight_start":17,"highlight_end":43}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"...which requires const-evaluating `Foo::bytes::{{constant}}`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/libcore/mem.rs","byte_start":9563,"byte_end":9589,"line_start":290,"line_end":290,"column_start":5,"column_end":31,"is_primary":true,"text":[{"text":"    intrinsics::size_of::<T>()","highlight_start":5,"highlight_end":31}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires computing layout of `Foo`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/consts/const-size_of-cycle.rs","byte_start":0,"byte_end":0,"line_start":1,"line_end":1,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"// Copyright 2017 The Rust Project Developers. See the COPYRIGHT","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...","code":null,"leveed when const-evaluating + checking `Foo::bytes::{{constant}}`\n  --> /checkout/src/test/ui/consts/const-size_of-cycle.rs:14:17\n   |\nLL |     bytes: [u8; std::mem::size_of::<Foo>()]\n   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^\n   |\nnote: ...which requires const-evaluating `Foo::bytes::{{constant}}`...\n  --> /checkout/src/libcore/mem.rs:290:5\n   |\nLL |     intrinsics::size_of::<T>()\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires computing layout of `Foo`...\nnote: ...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...\nnote: ...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...\n  --> /checkout/src/test/ui/consts/const-size_of-cycle.rs:14:17\n   |\nLL |     bytes: [u8; std::mem::size_of::<Foo>()]\n   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^\n   = note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle\nnote: cycle used when processing `Foo`\n  --> /checkout/src/test/ui/consts/const-size_of-cycle.rs:13:1\n   |\nLL | struct Foo {\n   | ^^^^^^^^^^\n\n"}
[00:46:00] {"message":"aborting due to previous error","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to previous error\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0391`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0391`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/consts/const-size_of-cycle.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] 
[00:46:00] 
[00:46:00] ---- [ui] ui/issues/issue-44415.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 1 error[E0391]: cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`
[00:46:00] +   --> $DIR/issue-44415.rs:16:17
[00:46:00] 3    |
[00:46:00] 3    |
[00:46:00] 4 LL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],
[00:46:00] 
[00:46:00] 6    |
[00:46:00] 6    |
[00:46:00] 7 note: ...which requires const-evaluating `Foo::bytes::{{constant}}`...
[00:46:00] +   --> $DIR/issue-44415.rs:16:26
[00:46:00] 9    |
[00:46:00] 9    |
[00:46:00] 10 LL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],
[00:46:00] 
[00:46:00] 
[00:46:00] 12 note: ...which requires computing layout of `Foo`...
[00:46:00] 13 note: ...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...
[00:46:00] 14 note: ...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...
[00:46:00] +   --> $DIR/issue-44415.rs:16:17
[00:46:00] 16    |
[00:46:00] 16    |
[00:46:00] 17 LL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],
[00:46:00] 
[00:46:00] 
[00:46:00] 19    = note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle
[00:46:00] 20 note: cycle used when processing `Foo`
[00:46:00] +   --> $DIR/issue-44415.rs:15:1
[00:46:00] 22    |
[00:46:00] 22    |
[00:46:00] 23 LL | struct Foo {
[00:46:00] 
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-44415/issue-44415.stderr
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-44415/issue-44415.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args issues/issue-44415.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/issues/issue-44415.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-44415/a" "-Crpath" "-O" "-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/issues/issue-44415/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] {"message":"cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be construc{"message":"...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-44415.rs","byte_start":0,"byte_end":0,"line_start":1,"line_end":1,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"// Copyright 2018 The Rust Project Developers. See the COPYRIGHT","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-44415.rs","byte_start":548,"byte_end":554,"line_start":16,"line_end":16,"column_start":17,"column_end":23,"is_primary":true,"text":[{"text":"    bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],","highlight_start":17,"highlight_end":23}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"cycle used when processing `Foo`","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-44415.rs","byte_start":519,"byte_end":529,"line_start":15,"line_end":15,"column_start":1,"column_end":11,"is_primary":true,"text":[{"text":"struct Foo {","highlight_start":1,"highlight_end":11}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`\n  --> /checkout/src/test/ui/issues/issue-44415.rs:16:17\n   |\nLL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],\n   |                 ^^^^^^\n   |\nnote: ...which requires const-evaluating `Foo::bytes::{{constant}}`...\n  --> /checkout/src/test/ui/issues/issue-44415.rs:16:26\n   |\nLL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],\n   |                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires computing layout of `Foo`...\nnote: ...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...\nnote: ...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...\n  --> /checkout/src/test/ui/issues/issue-44415.rs:16:17\n   |\nLL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],\n   |                 ^^^^^^\n   = note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle\nnote: cycle used when processing `Foo`\n  --> /checkout/src/test/ui/issues/issue-44415.rs:15:1\n   |\nLL | struct Foo {\n   | ^^^^^^^^^^\n\n"}
[00:46:00] {"message":"aborting due to previous error","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to previous error\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0391`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0391`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/issues/issue-44415.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] 
[00:46:00] 
[00:46:00] ---- [ui] ui/issues/issue-52023-array-size-pointer-cast.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 6    |
[00:46:00] 7    = help: add #![feature(const_raw_ptr_to_usize_cast)] to the crate attributes to enable
[00:46:00] 8 
[00:46:00] - error: aborting due to previous error
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] +   --> $DIR/issue-52023-array-size-pointer-cast.rs:12:17
[00:46:00] +    |
[00:46:00] + LL |     let _ = [0; (&0 as *const i32) as usize]; //~ ERROR casting pointers to integers in constants
[00:46:00] +    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type usize
[00:46:00] +    |
[00:46:00] +    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - For more information about this error, try `rustc --explain E0658`.
[00:46:00] + error: aborting due to 2 previous errors
[00:46:00] + 
[00:46:00] + Some errors occurred: E0080, E0658.
[00:46:00] + Some errors occurred: E0080, E0658.
[00:46:00] + For more information about an error, try `rustc --explain E0080`.
[00:46:00] 12 
[00:46:00] 
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:d. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-52023-array-size-pointer-cast.rs","byte_start":495,"byte_end":522,"line_start":12,"line_end":12,"column_start":17,"column_end":44,"is_primary":true,"text":[{"text":"    let _ = [0; (&0 as *const i32) as usize]; //~ ERROR casting pointers to integers in constants","highlight_start":17,"highlight_end":44}],"label":"type validation failed: encountered a pointer, but expected the type usize","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/issues/issue-52023-array-size-pointer-cast.rs:12:17\n   |\nLL |     let _ = [0; (&0 as *const i32) as usize]; //~ ERROR casting pointers to integers in constants\n   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected_time:start:073563c9
Tue Sep  4 10:08:05 UTC 2018
Tue, 04 Sep 2018 10:08:05 GMT
9812 ./obj/build/x86_64-unknown-linux-gnu/stage0-bootstrap-tools/x86_64-unknown-linux-gnu/release
128280 ./obj/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu
---
74020 ./obj/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rustlib/x86_64-unknown-linux-gnu/lib
72532 ./src/llvm/lib
71772 ./obj/build/x86_64-unknown-linux-gnu/doc/std
71728 ./obj/build/x86_64-unknown-linux-gnu/test
71724 ./obj/buir CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:00b00b08
travis_time:start:00b00b08
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:010dabd7
$ dmesg | grep -i kill

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)

Collaborator

rust-highfive commented Sep 4, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:44:08] ....................................................................................................
[00:44:11] ....................................................................................................
[00:44:14] ....................................................................................................
[00:44:17] ........i...........................................................................................
[00:44:21] .......................F.........................F............F................................F....
[00:44:27] ............................ii..iii.................................................................
[00:44:30] ....................................................................................................
[00:44:32] ....................................................................................................
[00:44:34] ....................................................................................................
---
[00:44:52] ....................................................................................................
[00:44:55] ....................................................................................................
[00:44:58] ....................................................................................................
[00:45:01] ....................................................................................................
[00:45:04] .......................................................................F............................
[00:45:07] ......................................................................................F.............
[00:45:13] ....................................................................................................
[00:45:16] ..........................................................i.........................................
[00:45:19] ....................................................................................................
[00:45:22] ........i.i..ii.....................................................................................
---
[00:46:00] 
[00:46:00] ---- [ui] ui/consts/const-eval/const-pointer-values-in-various-types.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] - error[E0080]: this constant likely exhibits undefined behavior
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] 3    |
[00:46:00] 3    |
[00:46:00] 4 LL |     const I32_REF_USIZE_UNION: usize = unsafe { Nonsense { int_32_ref: &3 }.u };
[00:46:00] 6    |
[00:46:00] 6    |
[00:46:00] 7    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 11    |
[00:46:00] 11    |
[00:46:00] 12 LL |     const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };
[00:46:00] 16    |
[00:46:00] 17    = note: #[deny(const_err)] on by default
[00:46:00] 18 
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 21    |
[00:46:00] 21    |
[00:46:00] 22 LL |     const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };
[00:46:00] 24    |                                             |
[00:46:00] 24    |                                             |
[00:46:00] 25    |                                             a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 29    |
[00:46:00] 29    |
[00:46:00] 30 LL |     const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };
[00:46:00] 32    |                                             |
[00:46:00] 32    |                                             |
[00:46:00] 33    |                                             a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] 34 
[00:46:00] - error[E0080]: this constant likely exhibits undefined behavior
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] 37    |
[00:46:00] 37    |
[00:46:00] 38 LL |     const I32_REF_U64_UNION: u64 = unsafe { Nonsense { int_32_ref: &3 }.uint_64 };
[00:46:00] 40    |
[00:46:00] 40    |
[00:46:00] 41    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 45    |
[00:46:00] 45    |
[00:46:00] 46 LL |     const I32_REF_U128_UNION: u128 = unsafe { Nonsense { int_32_ref: &3 }.uint_128 };
[00:46:00] 47    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempted to read undefined bytes
[00:46:00] 48 
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 51    |
[00:46:00] 51    |
[00:46:00] 52 LL |     const I32_REF_I8_UNION: i8 = unsafe { Nonsense { int_32_ref: &3 }.int_8 };
[00:46:00] 54    |                                           |
[00:46:00] 54    |                                           |
[00:46:00] 55    |        en't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 105    |
[00:46:00] 105    |
[00:46:00] 106 LL |     const I32_REF_BOOL_UNION: bool = unsafe { Nonsense { int_32_ref: &3 }.truthy_falsey };
[00:46:00] 108    |                                               |
[00:46:00] 108    |                                               |
[00:46:00] 109    |                                               a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 113    |
[00:46:00] 113    |
[00:46:00] 114 LL |     const I32_REF_CHAR_UNION: char = unsafe { Nonsense { int_32_ref: &3 }.character };
[00:46:00] 116    |                                               |
[00:46:00] 116    |                                               |
[00:46:00] 117    |                                               a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 121    |
[00:46:00] 121    |
[00:46:00] 122 LL |     const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: "3" }.uint_8 };
[00:46:00] 
[00:46:00] 124    |                          :46:00] 173    |                                         a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 177    |
[00:46:00] 177    |
[00:46:00] 178 LL |     const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: "3" }.int_32 };
[00:46:00] 180    |                                         |
[00:46:00] 180    |                                         |
[00:46:00] 181    |                                         a raw memory access tried to access part of a pointer value as raw bytes
[00:46:00] 182 
[00:46:00] - error[E0080]: this constant likely exhibits undefined behavior
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] 185    |
[00:46:00] 185    |
[00:46:00] 186 LL |     const STR_I64_UNION: i64 = unsafe { Nonsense { stringy: "3" }.int_64 };
[00:46:00] 188    |
[00:46:00] 188    |
[00:46:00] 189    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - error: this constant cannot be used
[00:46:00] - error: this constant cannot be used
[00:46:00] + error: any use of this value will cause an error
[00:46:00] 193    |
[00:46:00] 193    |
[00:46:00] 194 LL |     const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: "3" }.int_128 };
[00:46:00] 
[00:46:00] 196    |     " "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/const-pointer-values-in-various-types/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":382,"byte_end":458,"line_start":24,"line_end":24,"column_start":5,"column_end":81,"is_primary":true,"text":[{"text":"    const I32_REF_USIZE_UNION: usize = unsafe { Nonsense { int_32_ref: &3 }.u };","highlight_start":5,"highlight_end":81}],"label":"type validation failed: encountered a pointer, but expected the type usize","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:24:5\n   |\nLL |     const I32_REF_USIZE_UNION: usize = unsafe { Nonsense { int_32_ref: &3 }.u };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type usize\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":566,"byte_end":600,"line_start":27,"line_end":27,"column_start":43,"column_end":77,"is_primary":false,"text":[{"text":"    const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };","highlight_start":43,"highlight_end":77}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":528,"byte_end":603,"line_start":27,"line_end":27,"column_start":5,"column_end":80,"is_primary":true,"text":[{"text":"    const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };","highlight_start":5,"highlight_end":80}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"#[deny(const_err)] on by default","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:27:5\n   |\nLL |     const I32_REF_U8_UNION: u8 = unsafe { Nonsense { int_32_ref: &3 }.uint_8 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^----------------------------------^^^\n   |                                           |\n   |                                           a raw memory access tried to access part of a pointer value as raw bytes\n   |\n   = note: #[deny(const_err)] on by default\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":693,"byte_end":728,"line_start":30,"line_end":30,"column_start":45,"column_end":80,"is_primary":false,"text":[{"text":"    const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };","highlight_start":45,"highlight_end":80}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":653,"byte_end":731,"line_start":30,"line_end":30,"column_start":5,"column_end":83,"is_primary":true,"text":[{"text":"    const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };","highlight_start":5,"highlight_end":83}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:30:5\n   |\nLL |     const I32_REF_U16_UNION: u16 = unsafe { Nonsense { int_32_ref: &3 }.uint_16 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":821,"byte_end":856,"line_start":33,"line_end":33,"column_start":45,"column_end":80,"is_primary":false,"text":[{"text":"    const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };","highlight_start":45,"highlight_end":80}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":781,"byte_end":859,"line_start":33,"line_end":33,"column_start":5,"column_end":83,"is_primary":true,"text":[{"text":"    const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };","highlight_start":5,"highlight_end":83}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:33:5\n   |\nLL |     const I32_REF_U32_UNION: u32 = unsafe { Nonsense { int_32_ref: &3 }.uint_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":909,"byte_end":987,"line_start":36,"line_end":36,"column_start":5,"column_end":83,"is_primary":true,"text":[{"text":"    const I32_REF_U64_UNION: u64 = unsafe { Nonsense { int_32_ref: &3 }.uint_64 };","highlight_start":5,"highlight_end":83}],"label":"type validation failed: encountered a pointer, but expected the type u64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:36:5\n   |\nLL |     const I32_REF_U64_UNION: u64 = unsafe { Nonsense { int_32_ref: &3 }.uint_64 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type u64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1057,"byte_end":1138,"line_start":39,"line_end":39,"column_start":5,"column_end":86,"is_primary":true,"text":[{"text":"    const I32_REF_U128_UNION: u128 = unsafe { Nonsense { int_32_ref: &3 }.uint_128 };","highlight_start":5,"highlight_end":86}],"label":"attempted to read undefined bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:39:5\n   |\nLL |     const I32_REF_U128_UNION: u128 = unsafe { Nonsense { int_32_ref: &3 }.uint_128 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempted to read undefined bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1226,"byte_end":1259,"line_start":42,"line_end":42,"column_start":43,"column_end":76,"is_primary":false,"text":[{"text":"    const I32_REF_I8_UNION: i8 = unsafe { Nonsense { int_32_ref: &3 }.int_8 };","highlight_start":43,"highlight_end":76}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1188,"byte_end":1262,"line_start":42,"line_end":42,"column_start":5,"columI32_REF_I32_UNION: i32 = unsafe { Nonsense { int_32_ref: &3 }.int_32 };","highlight_start":5,"highlight_end":82}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:48:5\n   |\nLL |     const I32_REF_I32_UNION: i32 = unsafe { Nonsense { int_32_ref: &3 }.int_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^----------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1566,"byte_end":1643,"line_start":51,"line_end":51,"column_start":5,"column_end":82,"is_primary":true,"text":[{"text":"    c:null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:57:5\n   |\nLL |     const I32_REF_F32_UNION: f32 = unsafe { Nonsense { int_32_ref: &3 }.float_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^------------------------------------^^^\n   |                                             |\n   |                                             a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":1972,"byte_end":2051,"line_start":60,"line_end":60,"column_start":5,"column_end":84,"is_primary":true,"text":[{"text":"    const I32_REF_F64_UNION: f64 = unsafe { Nonsense { int_32_ref: &3 }.float_64 };","highlight_start":5,"highlight_end":84}],"label":"type validation ied to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2257,"byte_end":2339,"line_start":66,"line_end":66,"column_start":5,"column_end":87,"is_primary":true,"text":[{"text":"    const I32_REF_CHAR_UNION: char = unsafe { Nonsense { int_32_ref: &3 }.character };","highlight_start":5,"highlight_end":87}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:66:5\n   |\nLL |     const I32_REF_CHAR_UNION: char = unsafe { Nonsense { int_32_ref: &3 }.character };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-------------------------------------^^^\n   |                                               |\n   |                                               a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2423,"byte_end":2455,"line_start":69,"line_end":69,"column_start":39,"column_end":71,"is_primary":false,"text":[{"text":"    const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: \"3\" }.uint_8 };","highlight_start":39,"highlight_end":71}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2389,"byte_end":2458,"line_start":69,"line_end":69,"column_start":5,"column_end":74,"is_primary":true,"text":[{"text":"    const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: \"3\" }.uint_8 };","highlight_start":5,"highlight_end":74}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:69:5\n   |\nLL |     const STR_U8_UNION: u8 = unsafe { Nonsense { stringy: \"3\" }.uint_8 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------------------^^^\n   |                                       |\n   |                                       a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2544,"byte_end":2577,"line_start":72,"line_end":72,"column_start":41,"column_end":74,"is_primary":false,"text":[{"text":"    const STR_U16_UNION: u16 = unsafe { Nonsense { stringy: \"3\" }.uint_16 };","highlight_start":41,"highlight_end":74}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2508,"byte_end":2580,"line_start":72,"line_end":72,"column_start":5,"column_end":77,"is_primary":true,"text":[{"text":"    const STR_U16_UNION: u16 = unsafe { Nonsense { stringy: \"3\" }.uint_16 };","highlight_start":5,"highlight_end":77}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:72:5\n   |\nLL |     const STR_U16_UNION: u16 = unsafe { Nonsense { stringy: \"3\" }.uint_16 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^---------------------------------^^^\n   |                                         |\n   |                                         a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2666,"byte_end":2699,"line_start":75,"line_end":75,"column_start":41,"column_end":74,"is_primary":false,"text":[{"text":"    const STR_U32_UNION: u32 = unsafe { Nonsense { stringy: \"3\" }.uint_32 };","highlight_start":41,"highlight_end":74}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2752,"byte_end":2824,"line_start":78,"line_end":78,"column_start":5,"column_end":77,"is_primary":true,"text":[{"text":"    const STR_U64_UNION: u64 = unsafe { Nonsense { stringy: \"3\" }.uint_64 };","highlight_start":5,"highlight_end":77}],"label":"type validation failed: encountered a pointer, but expected the type u64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:78:5\n   |\nLL |     const STR_U64_UNION: u64 = unsafe { Nonsense { stringy: \"3\" }.uint_64 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type u64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2932,"byte_end":2966,"line_start":81,"line_end":81,"column_start":43,"column_end":77,"is_primary":false,"text":[{"text":"    const STR_U128_UNION: u128 = unsafe { Nonsense { stringy: \"3\" }.uint_128 };","highlight_start":43,"highlight_end":77}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":2894,"byte_end":2969,"line_start":81,"line_end":81,"column_start":5,"column_end":80,"is_primary":true,"text":[{"text":"    const STR_U128_UNION: u128 = unsafe { Nonsense { stringy: \"3\" }.uint_128 };","highlight_start":5,"highlight_end":80}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:81:5\n   |\nLL |     const STR_U128_UNION: u128 = unsafe { Nonsense { stringy: \"3\" }.uint_128 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^----------------------------------^^^\n   |                                           |\n   |                                           a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-point5,"line_start":87,"line_end":87,"column_start":41,"column_end":73,"is_primary":false,"text":[{"text":"    const STR_I16_UNION: i16 = unsafe { Nonsense { stringy: \"3\" }.int_16 };","highlight_start":41,"highlight_end":73}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3137,"byte_end":3208,"line_start":87,"line_end":87,"column_start":5,"column_end":76,"is_primary":true,"text":[{"text":"    const STR_I16_UNION: i16 = unsafe { Nonsense { stringy: \"3\" }.int_16 };","highlight_start":5,"highlight_end":76}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:87:5\n   |\nLL |     const STR_I16_UNION: i16 = unsafe { Nonsense { stringy: \"3\" }.int_16 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------------------^^^\n   |                                         |\n   |                                         a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3294,"byte_end":3326,"line_start":90,"line_end":90,"column_start":41,"column_end":73,"is_primary":false,"text":[{"text":"    const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: \"3\" }.int_32 };","highlight_start":41,"highlight_end":73}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3258,"byte_end":3329,"line_start":90,"line_end":90,"column_start":5,"column_end":76,"is_primary":true,"text":[{"text":"    const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: \"3\" }.int_32 };","highlight_start":5,"highlight_end":76}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:90:5\n   |\nLL |     const STR_I32_UNION: i32 = unsafe { Nonsense { stringy: \"3\" }.int_32 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------------------^^^\n   |                                         |\n   |                                         a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3379,"byte_end":3450,"line_start":93,"line_end":93,"column_start":5,"column_end":76,"is_primary":true,"text":[{"text":"    const STR_I64_UNION: i64 = unsafe { Nonsense { stringy: \"3\" }.int_64 };","highlight_start":5,"highlight_end":76}],"label":"type validation failed: encountered a pointer, but expected the type i64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:93:5\n   |\nLL |     const STR_I64_UNION: i64 = unsafe { Nonsense { stringy: \"3\" }.int_64 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type i64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"any use of this value will cause an error","code":{"code":"const_err","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3558,"byte_end":3591,"line_start":96,"line_end":96,"column_start":43,"column_end":76,"is_primary":false,"text":[{"text":"    const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: \"3\" }.int_128 };","highlight_start":43,"highlight_end":76}],"label":"a raw memory access tried to access part of a pointer value as raw bytes","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3520,"byte_end":3594,"line_start":96,"line_end":96,"column_start":5,"column_end":79,"is_primary":true,"text":[{"text":"    const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: \"3\" }.int_128 };","highlight_start":5,"highlight_end":79}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:96:5\n   |\nLL |     const STR_I128_UNION: i128 = unsafe { Nonsense { stringy: \"3\" }.int_128 };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^---------------------------------^^^\n   |                                           |\n   |                      s tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs","byte_start":3767,"byte_end":3840,"line_start":102,"line_end":102,"column_start":5,"column_end":78,"is_primary":true,"text":[{"text":"    const STR_F64_UNION: f64 = unsafe { Nonsense { stringy: \"3\" }.float_64 };","highlight_start":5,"highlight_end":78}],"label":"type validation failed: encountered a pointer, but expected the type f64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/snsion":null}],"children":[],"rendered":"error: any use of this value will cause an error\n  --> /checkout/src/test/ui/consts/const-eval/const-pointer-values-in-various-types.rs:108:5\n   |\nLL |     const STR_CHAR_UNION: char = unsafe { Nonsense { stringy: \"3\" }.character };\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-----------------------------------^^^\n   |                                           |\n   |                                           a raw memory access tried to access part of a pointer value as raw bytes\n\n"}
[00:46:00] {"message":"aborting due to 29 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 29 previous errors\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0080`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0080`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/consts/const-eval/const-pointer-values-in-various-types.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:46:00] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:46:00] 
[00:46:00] ---- [ui] ui/consts/const-eval/issue-52442.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 4 LL |     [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type
[00:46:00] 6 
[00:46:00] - error: aborting due to previous error
[00:46:00] - error: aborting due to previous error
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] +   --> $DIR/issue-52442.rs:12:11
[00:46:00] +    |
[00:46:00] + LL |     [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type
[00:46:00] +    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type usize
[00:46:00] +    |
[00:46:00] +    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - For more information about this error, try `rustc --explain E0019`.
[00:46:00] + error: aborting due to 2 previous errors
[00:46:00] + 
[00:46:00] + Some errors occurred: E0019, E0080.
[00:46:00] + Some errors occurred: E0019, E0080.
[00:46:00] + For more information about an error, try `rustc --explain E0019`.
[00:46:00] 10 
[00:46:00] 
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/issue-52442/issue-52442.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args consts/const-eval/issue-52442.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-eval/issue-52442.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic"  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type","highlight_start":14,"highlight_end":28}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0019]: constant contains unimplemented expression type\n  --> /checkout/src/test/ui/consts/const-eval/issue-52442.rs:12:14\n   |\nLL |     [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type\n   |              ^^^^^^^^^^^^^^\n\n"}
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52442.rs","byte_start":489,"byte_end":529,"line_start":12,"line_end":12,"column_start":11,"column_end":51,"is_primary":true,"text":[{"text":"    [();  { &loop { break } as *const _ as usize } ]; //~ ERROR unimplemented expression type","highlight_start":11,"highlight_end":51}],"label":"type validation failed: encountered a pointer, but expected the type usize","suggested_replacement":0] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ref_to_int_match/ref_to_int_match.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args consts/const-eval/ref_to_int_match.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-eval/ref_to_int_match/a" "-Crpath" "-O" "-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/consts/const-eval/ref_to_int_match/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:46:00] {"message":"it is undefined behavior to use this value","code":{"code":"E0080","explanation":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs","byte_start":829,"byte_end":874,"line_start":33,"line_end":33,"column_start":1,"column_end":46,"is_primary":true,"text":[{"text":"const BAR: Int = unsafe { Foo { r: &42 }.f };","highlight_start":1,"highlight_end":46}],"label":"type validation failed: encountered a pointer, but expected the type u64","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs:33:1\n   |\nLL | const BAR: Int = unsafe { Foo { r: &42 }.f };\n   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type u64\n   |\n   = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior\n\n"}
[00:46:00] {"message":"could not evaluate constant pattern","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs","byte_start":578,"byte_end":581,"line_start":17,"line_end":17,"column_start":14,"column_end":17,"is_primary":true,"text":[{"text":"        10..=BAR => {}, //~ ERROR lower range bound must be less than or equal to upper","highlight_start":14,"highlight_end":17}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error: could not evaluate constant pattern\n  --> /checkout/src/test/ui/consts/const-eval/ref_to_int_match.rs:17:14\n   |\nLL |         10..=BAR => {}, //~ ERROR lower range bound must be less than or equal to upper\n   |              ^^^\n\n"}
[00:46:00] {"message":"aborting due to 2 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 2 previous errors\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0080`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0080`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/consts/const-eval/ref_to_int_match.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] 
[00:46:00] 
[00:46:00] ---- [ui] ui/consts/const-size_of-cycle.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 1 error[E0391]: cycle de | ^^^^^^^^^^
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-size_of-cycle/const-size_of-cycle.stderr
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-size_of-cycle/const-size_of-cycle.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args consts/const-size_of-cycle.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/consts/const-size_of-cycle.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/consts/const-size_of-cycle/a" "-Crpath" "-O" "-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/consts/const-size_of-cycle/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] {"message":"cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be constructed.\n\nThe following example contains a circular dependency between two traits:\n\n```compile_fail,E0391\ntrait FirstTrait : SecondTrait {\n\n}\n\ntrait SecondTrait : FirstTrait {\n\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-size_of-cycle.rs","byte_start":530,"byte_end":556,"line_start":14,"line_end":14,"column_start":17,"column_end":43,"is_primary":true,"text":[{"text":"    bytes: [u8; std::mem::size_of::<Foo>()]","highlight_start":17,"highlight_end":43}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"...which requires const-evaluating `Foo::bytes::{{constant}}`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/libcore/mem.rs","byte_start":9563,"byte_end":9589,"line_start":290,"line_end":290,"column_start":5,"column_end":31,"is_primary":true,"text":[{"text":"    intrinsics::size_of::<T>()","highlight_start":5,"highlight_end":31}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires computing layout of `Foo`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/consts/const-size_of-cycle.rs","byte_start":0,"byte_end":0,"line_start":1,"line_end":1,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"// Copyright 2017 The Rust Project Developers. See the COPYRIGHT","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...","code":null,"leveed when const-evaluating + checking `Foo::bytes::{{constant}}`\n  --> /checkout/src/test/ui/consts/const-size_of-cycle.rs:14:17\n   |\nLL |     bytes: [u8; std::mem::size_of::<Foo>()]\n   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^\n   |\nnote: ...which requires const-evaluating `Foo::bytes::{{constant}}`...\n  --> /checkout/src/libcore/mem.rs:290:5\n   |\nLL |     intrinsics::size_of::<T>()\n   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires computing layout of `Foo`...\nnote: ...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...\nnote: ...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...\n  --> /checkout/src/test/ui/consts/const-size_of-cycle.rs:14:17\n   |\nLL |     bytes: [u8; std::mem::size_of::<Foo>()]\n   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^\n   = note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle\nnote: cycle used when processing `Foo`\n  --> /checkout/src/test/ui/consts/const-size_of-cycle.rs:13:1\n   |\nLL | struct Foo {\n   | ^^^^^^^^^^\n\n"}
[00:46:00] {"message":"aborting due to previous error","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to previous error\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0391`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0391`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/consts/const-size_of-cycle.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] 
[00:46:00] 
[00:46:00] ---- [ui] ui/issues/issue-44415.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 1 error[E0391]: cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`
[00:46:00] +   --> $DIR/issue-44415.rs:16:17
[00:46:00] 3    |
[00:46:00] 3    |
[00:46:00] 4 LL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],
[00:46:00] 
[00:46:00] 6    |
[00:46:00] 6    |
[00:46:00] 7 note: ...which requires const-evaluating `Foo::bytes::{{constant}}`...
[00:46:00] +   --> $DIR/issue-44415.rs:16:26
[00:46:00] 9    |
[00:46:00] 9    |
[00:46:00] 10 LL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],
[00:46:00] 
[00:46:00] 
[00:46:00] 12 note: ...which requires computing layout of `Foo`...
[00:46:00] 13 note: ...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...
[00:46:00] 14 note: ...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...
[00:46:00] +   --> $DIR/issue-44415.rs:16:17
[00:46:00] 16    |
[00:46:00] 16    |
[00:46:00] 17 LL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],
[00:46:00] 
[00:46:00] 
[00:46:00] 19    = note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle
[00:46:00] 20 note: cycle used when processing `Foo`
[00:46:00] +   --> $DIR/issue-44415.rs:15:1
[00:46:00] 22    |
[00:46:00] 22    |
[00:46:00] 23 LL | struct Foo {
[00:46:00] 
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-44415/issue-44415.stderr
[00:46:00] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-44415/issue-44415.stderr
[00:46:00] To update references, rerun the tests and pass the `--bless` flag
[00:46:00] To only update this specific test, also pass `--test-args issues/issue-44415.rs`
[00:46:00] error: 1 errors occurred comparing output.
[00:46:00] status: exit code: 1
[00:46:00] status: exit code: 1
[00:46:00] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/issues/issue-44415.rs" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-44415/a" "-Crpath" "-O" "-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/issues/issue-44415/auxiliary" "-A" "unused"
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] ------------------------------------------
[00:46:00] stderr:
[00:46:00] stderr:
[00:46:00] ------------------------------------------
[00:46:00] {"message":"cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`","code":{"code":"E0391","explanation":"\nThis error indicates that some types or traits depend on each other\nand therefore cannot be construc{"message":"...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-44415.rs","byte_start":0,"byte_end":0,"line_start":1,"line_end":1,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"// Copyright 2018 The Rust Project Developers. See the COPYRIGHT","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-44415.rs","byte_start":548,"byte_end":554,"line_start":16,"line_end":16,"column_start":17,"column_end":23,"is_primary":true,"text":[{"text":"    bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],","highlight_start":17,"highlight_end":23}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"cycle used when processing `Foo`","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-44415.rs","byte_start":519,"byte_end":529,"line_start":15,"line_end":15,"column_start":1,"column_end":11,"is_primary":true,"text":[{"text":"struct Foo {","highlight_start":1,"highlight_end":11}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0391]: cycle detected when const-evaluating + checking `Foo::bytes::{{constant}}`\n  --> /checkout/src/test/ui/issues/issue-44415.rs:16:17\n   |\nLL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],\n   |                 ^^^^^^\n   |\nnote: ...which requires const-evaluating `Foo::bytes::{{constant}}`...\n  --> /checkout/src/test/ui/issues/issue-44415.rs:16:26\n   |\nLL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],\n   |                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nnote: ...which requires computing layout of `Foo`...\nnote: ...which requires normalizing `ParamEnvAnd { param_env: ParamEnv { caller_bounds: [], reveal: All }, value: [u8; _] }`...\nnote: ...which requires const-evaluating + checking `Foo::bytes::{{constant}}`...\n  --> /checkout/src/test/ui/issues/issue-44415.rs:16:17\n   |\nLL |     bytes: [u8; unsafe { intrinsics::size_of::<Foo>() }],\n   |                 ^^^^^^\n   = note: ...which again requires const-evaluating + checking `Foo::bytes::{{constant}}`, completing the cycle\nnote: cycle used when processing `Foo`\n  --> /checkout/src/test/ui/issues/issue-44415.rs:15:1\n   |\nLL | struct Foo {\n   | ^^^^^^^^^^\n\n"}
[00:46:00] {"message":"aborting due to previous error","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to previous error\n\n"}
[00:46:00] {"message":"For more information about this error, try `rustc --explain E0391`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0391`.\n"}
[00:46:00] ------------------------------------------
[00:46:00] 
[00:46:00] thread '[ui] ui/issues/issue-44415.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:00] 
[00:46:00] 
[00:46:00] ---- [ui] ui/issues/issue-52023-array-size-pointer-cast.rs stdout ----
[00:46:00] diff of stderr:
[00:46:00] 
[00:46:00] 6    |
[00:46:00] 7    = help: add #![feature(const_raw_ptr_to_usize_cast)] to the crate attributes to enable
[00:46:00] 8 
[00:46:00] - error: aborting due to previous error
[00:46:00] + error[E0080]: it is undefined behavior to use this value
[00:46:00] +   --> $DIR/issue-52023-array-size-pointer-cast.rs:12:17
[00:46:00] +    |
[00:46:00] + LL |     let _ = [0; (&0 as *const i32) as usize]; //~ ERROR casting pointers to integers in constants
[00:46:00] +    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected the type usize
[00:46:00] +    |
[00:46:00] +    = note: The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior
[00:46:00] - For more information about this error, try `rustc --explain E0658`.
[00:46:00] + error: aborting due to 2 previous errors
[00:46:00] + 
[00:46:00] + Some errors occurred: E0080, E0658.
[00:46:00] + Some errors occurred: E0080, E0658.
[00:46:00] + For more information about an error, try `rustc --explain E0080`.
[00:46:00] 12 
[00:46:00] 
[00:46:00] 
[00:46:00] The actual stderr differed from the expected stderr.
[00:d. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-52023-array-size-pointer-cast.rs","byte_start":495,"byte_end":522,"line_start":12,"line_end":12,"column_start":17,"column_end":44,"is_primary":true,"text":[{"text":"    let _ = [0; (&0 as *const i32) as usize]; //~ ERROR casting pointers to integers in constants","highlight_start":17,"highlight_end":44}],"label":"type validation failed: encountered a pointer, but expected the type usize","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"The rules on what exactly is undefined behavior aren't clear, so this check might be overzealous. Please open an issue on the rust compiler repository if you believe it should not be considered undefined behavior","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"error[E0080]: it is undefined behavior to use this value\n  --> /checkout/src/test/ui/issues/issue-52023-array-size-pointer-cast.rs:12:17\n   |\nLL |     let _ = [0; (&0 as *const i32) as usize]; //~ ERROR casting pointers to integers in constants\n   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered a pointer, but expected_time:start:073563c9
Tue Sep  4 10:08:05 UTC 2018
Tue, 04 Sep 2018 10:08:05 GMT
9812 ./obj/build/x86_64-unknown-linux-gnu/stage0-bootstrap-tools/x86_64-unknown-linux-gnu/release
128280 ./obj/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu
---
74020 ./obj/build/x86_64-unknown-linux-gnu/stage0-sysroot/lib/rustlib/x86_64-unknown-linux-gnu/lib
72532 ./src/llvm/lib
71772 ./obj/build/x86_64-unknown-linux-gnu/doc/std
71728 ./obj/build/x86_64-unknown-linux-gnu/test
71724 ./obj/buir CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:00b00b08
travis_time:start:00b00b08
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:010dabd7
$ dmesg | grep -i kill

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)

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Sep 4, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:47:47] ....................................................................................................
[00:47:50] ....................................................................................................
[00:47:52] ............................i.......................................................................
[00:47:55] ....................................................................................................
[00:47:58] .............................................................................iiiiiiiii..............
[00:48:03] i...................................................................................................
[00:48:07] ....................................................................................................
[00:48:10] ..........................................................i.........................................
[00:48:12] ....................................................................................................
---
[00:55:13] ---- [codegen-units] codegen-units/partitioning/vtable-through-const.rs stdout ----
[00:55:13] 
[00:55:13] These items were contained but should not have been:
[00:55:13] 
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::Trait2[0]::do_something[0]<u32> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::Trait2[0]::do_something_else[0]<u32> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::id[0]<i64> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::{{impl}}[3]::do_something[0]<u8> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::{{impl}}[3]::do_something_else[0]<u8> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] 
[00:55:13] thread '[codegen-units] codegen-units/partitioning/vtable-through-const.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:2291:13
[00:55:13] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:55:13] 
---
[00:55:13] 
[00:55:13] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:55:13] 
[00:55:13] 
[00:55:13] 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/codegen-units" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/codegen-units" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "codegen-units" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -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" "5.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[00:55:13] 
[00:55:13] 
[00:55:13] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[00:55:13] Build completed unsuccessfully in 0:11:22
[00:55:13] Build completed unsuccessfully in 0:11:22
[00:55:13] Makefile:58: recipe for target 'check' failed
[00:55:13] make: *** [check] Error 1

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:010aedcf
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
---
travis_time:end:02a9ca38:start=1536060213691494067,finish=1536060213781784126,duration=90290059
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:1fc55462
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:15969168
$ dmesg | grep -i kill

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)

Collaborator

rust-highfive commented Sep 4, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:47:47] ....................................................................................................
[00:47:50] ....................................................................................................
[00:47:52] ............................i.......................................................................
[00:47:55] ....................................................................................................
[00:47:58] .............................................................................iiiiiiiii..............
[00:48:03] i...................................................................................................
[00:48:07] ....................................................................................................
[00:48:10] ..........................................................i.........................................
[00:48:12] ....................................................................................................
---
[00:55:13] ---- [codegen-units] codegen-units/partitioning/vtable-through-const.rs stdout ----
[00:55:13] 
[00:55:13] These items were contained but should not have been:
[00:55:13] 
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::Trait2[0]::do_something[0]<u32> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::Trait2[0]::do_something_else[0]<u32> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::id[0]<i64> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::{{impl}}[3]::do_something[0]<u8> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] MONO_ITEM fn vtable_through_const::mod1[0]::{{impl}}[3]::do_something_else[0]<u8> @@ vtable_through_const.7rcbfp3g-mod1.volatile[Internal]
[00:55:13] 
[00:55:13] thread '[codegen-units] codegen-units/partitioning/vtable-through-const.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:2291:13
[00:55:13] note: Run with `RUST_BACKTRACE=1` for a backtrace.
[00:55:13] 
---
[00:55:13] 
[00:55:13] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:55:13] 
[00:55:13] 
[00:55:13] 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/codegen-units" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/codegen-units" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "codegen-units" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -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" "5.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[00:55:13] 
[00:55:13] 
[00:55:13] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[00:55:13] Build completed unsuccessfully in 0:11:22
[00:55:13] Build completed unsuccessfully in 0:11:22
[00:55:13] Makefile:58: recipe for target 'check' failed
[00:55:13] make: *** [check] Error 1

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:010aedcf
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
---
travis_time:end:02a9ca38:start=1536060213691494067,finish=1536060213781784126,duration=90290059
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:1fc55462
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:15969168
$ dmesg | grep -i kill

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)

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Sep 4, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:50:54] ....................................................................................................
[00:50:58] ....................................................................................................
[00:51:00] ............................i.......................................................................
[00:51:03] ....................................................................................................
[00:51:05] .............................................................................iiiiiiiii..............
[00:51:11] i...................................................................................................
[00:51:14] ....................................................................................................
[00:51:17] ...........................................................i........................................
[00:51:20] ....................................................................................................
---
travis_time:start:test_rustdoc
Check compiletest suite=rustdoc mode=rustdoc (x86_64-unknown-linux-gnu -> x86_64-unknown-linux-gnu)
[01:03:20] 
[01:03:20] running 258 tests
[01:03:47] ...........F...........i............................................................................
E0080]: evaluation of constant value failed
[01:04:20]   --> /checkout/src/test/rustdoc/const-evalutation-ice.rs:20:23
[01:04:20]    |
[01:04:20]    |
[01:04:20] 20 | pub type _S = [usize; 0 - (mem::size_of::<S>() != 4) as usize];
[01:04:20]    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to subtract with overflow
[01:04:20] 
[01:04:20] ------------------------------------------
[01:04:20] 
[01:04:20] thread '[rustdoc] rustdoc/const-evalutation-ice.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
---
[01:04:20] test result: FAILED. 255 passed; 1 failed; 2 ignored; 0 measured; 0 filtered out
[01:04:20] 
[01:04:20] 
[01:04:20] 
[01:04:20] 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" "--rustdoc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustdoc" "--src-base" "/checkout/src/test/rustdoc" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/rustdoc" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "rustdoc" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -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" "5.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[01:04:20] 
[01:04:20] 
[01:04:20] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[01:04:20] Build completed unsuccessfully in 0:17:29
[01:04:20] Build completed unsuccessfully in 0:17:29
[01:04:20] Makefile:58: recipe for target 'check' failed
[01:04:20] make: *** [check] Error 1

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:1310d220
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)

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)

Collaborator

rust-highfive commented Sep 4, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:50:54] ....................................................................................................
[00:50:58] ....................................................................................................
[00:51:00] ............................i.......................................................................
[00:51:03] ....................................................................................................
[00:51:05] .............................................................................iiiiiiiii..............
[00:51:11] i...................................................................................................
[00:51:14] ....................................................................................................
[00:51:17] ...........................................................i........................................
[00:51:20] ....................................................................................................
---
travis_time:start:test_rustdoc
Check compiletest suite=rustdoc mode=rustdoc (x86_64-unknown-linux-gnu -> x86_64-unknown-linux-gnu)
[01:03:20] 
[01:03:20] running 258 tests
[01:03:47] ...........F...........i............................................................................
E0080]: evaluation of constant value failed
[01:04:20]   --> /checkout/src/test/rustdoc/const-evalutation-ice.rs:20:23
[01:04:20]    |
[01:04:20]    |
[01:04:20] 20 | pub type _S = [usize; 0 - (mem::size_of::<S>() != 4) as usize];
[01:04:20]    |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ attempt to subtract with overflow
[01:04:20] 
[01:04:20] ------------------------------------------
[01:04:20] 
[01:04:20] thread '[rustdoc] rustdoc/const-evalutation-ice.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
---
[01:04:20] test result: FAILED. 255 passed; 1 failed; 2 ignored; 0 measured; 0 filtered out
[01:04:20] 
[01:04:20] 
[01:04:20] 
[01:04:20] 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" "--rustdoc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustdoc" "--src-base" "/checkout/src/test/rustdoc" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/rustdoc" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "rustdoc" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -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" "5.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[01:04:20] 
[01:04:20] 
[01:04:20] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[01:04:20] Build completed unsuccessfully in 0:17:29
[01:04:20] Build completed unsuccessfully in 0:17:29
[01:04:20] Makefile:58: recipe for target 'check' failed
[01:04:20] make: *** [check] Error 1

The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:1310d220
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)

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)

@bors

This comment was marked as outdated.

Show comment
Hide comment
@bors

bors Sep 6, 2018

Contributor

☔️ The latest upstream changes (presumably #52626) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Sep 6, 2018

☔️ The latest upstream changes (presumably #52626) made this pull request unmergeable. Please resolve the merge conflicts.

@rust-highfive

This comment was marked as outdated.

Show comment
Hide comment
@rust-highfive

rust-highfive Sep 7, 2018

Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:44:47] ....................................................................................................
[00:44:50] ....................................................................................................
[00:44:54] ........i...........................................................................................
[00:44:59] ....................................................................................................
[00:45:03] ...............i......F....i........................................................................
[00:45:06] ..................................iiiii.............................................................
[00:45:11] ....................................................................................................
[00:45:13] ....................................................................................................
[00:45:16] ....................................................................................................
[00:45:18] ....................................................................................................
---
[00:46:30] ...............................................................................................i....
[00:46:32] ....................................................................................................
[00:46:36] ....................................................................................................
[00:46:38] ....................................................................................................
 const's initialization\nexpression! However, you can totally use it anywhere else:\n\n```\nenum Test {\n    V1\n}\n\nimpl Test {\n    fn func(&self) -> i32 {\n        12\n    }\n}\n\nfn main() {\n    const FOO: Test = Test::V1;\n\n    FOO.func(); // here is good\n    let x = FOO.func(); // or even here!\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52475.rs","byte_start":716,"byte_end":875,"line_start":19,"line_end":22,"column_start":9,"column_end":10,"is_primary":true,"text":[{"text":"        while n < 5 { //~ ERROR constant contains unimplemented expression type","highlight_start":9,"highlight_end":80},{"text":"            n = (n + 1) % 5;","highlight_start":1,"highlight_end":29},{"text":"            x = &0; // Materialize a new AllocId","highlight_start":1,"highlight_end":49},{"text":"        }","highlight_start":1,"highlight_end":10}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0019]: constant contains unimplemented expression type\n  --> /checkout/src/test/ui/consts/const-eval/issue-52475.rs:19:9\n   |\nLL | /         while n < 5 { //~ ERROR constant contains unimplemented expression type\nLL | |             n = (n + 1) % 5;\nLL | |             x = &0; // Materialize a new AllocId\nLL | |         }\n   | |_________^\n\n"}
[00:46:41] {"message":"Constant evaluating a complex constant, this might take some time","code":null,"level":"warning","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52475.rs","byte_start":520,"byte_end":891,"line_start":14,"line_end":24,"column_station":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52475.rs","byte_start":804,"byte_end":815,"line_start":20,"line_end":20,"column_start":17,"column_end":28,"is_primary":true,"text":[{"text":"            n = (n + 1) % 5;","highlight_start":17,"highlight_end":28}],"label":"duplicate interpreter state observed here, const evaluation will never terminate","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0080]: evaluation of constant value failed\n  --> /checkout/src/test/ui/consts/const-eval/issue-52475.rs:20:17\n   |\nLL |             n = (n + 1) % 5;\n   |                 ^^^^^^^^^^^ duplicate interpreter state observed here, const evaluation will never terminate\n\n"}
[00:46:41] {"message":"aborting due to 2 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 2 previous errors\n\n"}
[00:46:41] {"message":"Some errors occurred: E0019, E0080.","code":null,"level":"","spans":[],"children":[],"rendered":"Some errors occurred: E0019, E0080.\n"}
[00:46:41] {"message":"For more information about an error, try `rustc --explain E0019`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about an error, try `rustc --explain E0019`.\n"}
[00:46:41] ------------------------------------------
[00:46:41] 
[00:46:41] thread '[ui] ui/consts/const-eval/issue-52475.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:41] note: Run with `RUST_BACKTRACE=1` for a backtrace.
---
[00:46:41] 
[00:46:41] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:46:41] 
[00:46:41] 
[00:46:41] 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-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -Zunsttravis_time:start:0a8c6270
Fri Sep  7 08:25:02 UTC 2018
Fri, 07 Sep 2018 08:25:02 GMT
travis_time:end:0a8c6270:start=1536308702797807691,finish=1536308702843685756,duration=45878065

---
travis_time:end:07fbaca4:start=1536308703913126239,finish=1536308703925905778,duration=12779539
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:061bafb6
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:14854fc4
$ dmesg | grep -i kill

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)

Collaborator

rust-highfive commented Sep 7, 2018

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (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.
[00:44:47] ....................................................................................................
[00:44:50] ....................................................................................................
[00:44:54] ........i...........................................................................................
[00:44:59] ....................................................................................................
[00:45:03] ...............i......F....i........................................................................
[00:45:06] ..................................iiiii.............................................................
[00:45:11] ....................................................................................................
[00:45:13] ....................................................................................................
[00:45:16] ....................................................................................................
[00:45:18] ....................................................................................................
---
[00:46:30] ...............................................................................................i....
[00:46:32] ....................................................................................................
[00:46:36] ....................................................................................................
[00:46:38] ....................................................................................................
 const's initialization\nexpression! However, you can totally use it anywhere else:\n\n```\nenum Test {\n    V1\n}\n\nimpl Test {\n    fn func(&self) -> i32 {\n        12\n    }\n}\n\nfn main() {\n    const FOO: Test = Test::V1;\n\n    FOO.func(); // here is good\n    let x = FOO.func(); // or even here!\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52475.rs","byte_start":716,"byte_end":875,"line_start":19,"line_end":22,"column_start":9,"column_end":10,"is_primary":true,"text":[{"text":"        while n < 5 { //~ ERROR constant contains unimplemented expression type","highlight_start":9,"highlight_end":80},{"text":"            n = (n + 1) % 5;","highlight_start":1,"highlight_end":29},{"text":"            x = &0; // Materialize a new AllocId","highlight_start":1,"highlight_end":49},{"text":"        }","highlight_start":1,"highlight_end":10}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0019]: constant contains unimplemented expression type\n  --> /checkout/src/test/ui/consts/const-eval/issue-52475.rs:19:9\n   |\nLL | /         while n < 5 { //~ ERROR constant contains unimplemented expression type\nLL | |             n = (n + 1) % 5;\nLL | |             x = &0; // Materialize a new AllocId\nLL | |         }\n   | |_________^\n\n"}
[00:46:41] {"message":"Constant evaluating a complex constant, this might take some time","code":null,"level":"warning","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52475.rs","byte_start":520,"byte_end":891,"line_start":14,"line_end":24,"column_station":"\nThis error indicates that the compiler was unable to sensibly evaluate an\nconstant expression that had to be evaluated. Attempting to divide by 0\nor causing integer overflow are two ways to induce this error. For example:\n\n```compile_fail,E0080\nenum Enum {\n    X = (1 << 500),\n    Y = (1 / 0)\n}\n```\n\nEnsure that the expressions given can be evaluated as the desired integer type.\nSee the FFI section of the Reference for more information about using a custom\ninteger type:\n\nhttps://doc.rust-lang.org/reference.html#ffi-attributes\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/consts/const-eval/issue-52475.rs","byte_start":804,"byte_end":815,"line_start":20,"line_end":20,"column_start":17,"column_end":28,"is_primary":true,"text":[{"text":"            n = (n + 1) % 5;","highlight_start":17,"highlight_end":28}],"label":"duplicate interpreter state observed here, const evaluation will never terminate","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0080]: evaluation of constant value failed\n  --> /checkout/src/test/ui/consts/const-eval/issue-52475.rs:20:17\n   |\nLL |             n = (n + 1) % 5;\n   |                 ^^^^^^^^^^^ duplicate interpreter state observed here, const evaluation will never terminate\n\n"}
[00:46:41] {"message":"aborting due to 2 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 2 previous errors\n\n"}
[00:46:41] {"message":"Some errors occurred: E0019, E0080.","code":null,"level":"","spans":[],"children":[],"rendered":"Some errors occurred: E0019, E0080.\n"}
[00:46:41] {"message":"For more information about an error, try `rustc --explain E0019`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about an error, try `rustc --explain E0019`.\n"}
[00:46:41] ------------------------------------------
[00:46:41] 
[00:46:41] thread '[ui] ui/consts/const-eval/issue-52475.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:3196:9
[00:46:41] note: Run with `RUST_BACKTRACE=1` for a backtrace.
---
[00:46:41] 
[00:46:41] thread 'main' panicked at 'Some tests failed', tools/compiletest/src/main.rs:497:22
[00:46:41] 
[00:46:41] 
[00:46:41] 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-5.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options " "--target-rustcflags" "-Crpath -O -Zunsttravis_time:start:0a8c6270
Fri Sep  7 08:25:02 UTC 2018
Fri, 07 Sep 2018 08:25:02 GMT
travis_time:end:0a8c6270:start=1536308702797807691,finish=1536308702843685756,duration=45878065

---
travis_time:end:07fbaca4:start=1536308703913126239,finish=1536308703925905778,duration=12779539
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:061bafb6
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:14854fc4
$ dmesg | grep -i kill

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)

@bors

This comment was marked as outdated.

Show comment
Hide comment
@bors

bors Sep 8, 2018

Contributor

☔️ The latest upstream changes (presumably #51366) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Sep 8, 2018

☔️ The latest upstream changes (presumably #51366) made this pull request unmergeable. Please resolve the merge conflicts.

@oli-obk

This comment has been minimized.

Show comment
Hide comment
@oli-obk

oli-obk Sep 11, 2018

Contributor

If this PR ends up needing rebasing, I won't get to doing that until October 1st. I checked the "allow edits from maintainers" box, so feel free to rebase or apply small fixes to get this landed.

Contributor

oli-obk commented Sep 11, 2018

If this PR ends up needing rebasing, I won't get to doing that until October 1st. I checked the "allow edits from maintainers" box, so feel free to rebase or apply small fixes to get this landed.

@alexreg

This comment has been minimized.

Show comment
Hide comment
@alexreg

alexreg Sep 12, 2018

Contributor

How are we looking with this @RalfJung? I'm happy to finish things off here if any work needs doing while @oli-obk is away.

Contributor

alexreg commented Sep 12, 2018

How are we looking with this @RalfJung? I'm happy to finish things off here if any work needs doing while @oli-obk is away.

@RalfJung

This comment has been minimized.

Show comment
Hide comment
@RalfJung

RalfJung Sep 13, 2018

Member
Member

RalfJung commented Sep 13, 2018

@bors

This comment was marked as resolved.

Show comment
Hide comment
@bors

bors Oct 13, 2018

Contributor

☔️ The latest upstream changes (presumably #54955) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Oct 13, 2018

☔️ The latest upstream changes (presumably #54955) made this pull request unmergeable. Please resolve the merge conflicts.

@rfcbot

This comment has been minimized.

Show comment
Hide comment
@rfcbot

rfcbot Oct 15, 2018

🔔 This is now entering its final comment period, as per the review above. 🔔

rfcbot commented Oct 15, 2018

🔔 This is now entering its final comment period, as per the review above. 🔔

@bors

This comment has been minimized.

Show comment
Hide comment
@bors

bors Oct 19, 2018

Contributor

☔️ The latest upstream changes (presumably #55004) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Oct 19, 2018

☔️ The latest upstream changes (presumably #55004) made this pull request unmergeable. Please resolve the merge conflicts.

@bors

This comment has been minimized.

Show comment
Hide comment
@bors

bors Oct 19, 2018

Contributor

☔️ The latest upstream changes (presumably #55152) made this pull request unmergeable. Please resolve the merge conflicts.

Contributor

bors commented Oct 19, 2018

☔️ The latest upstream changes (presumably #55152) made this pull request unmergeable. Please resolve the merge conflicts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment