Description
When experimentally adding -Zinstrument-coverage
to the set of ui
tests in the Rust source tree, most tests still pass; of those that don't, almost all failures can be explained, and some improvements have been made to surface known incompatibilities between -Zinstrument-coverage
and other compiler options (see #79958 (comment)).
However, there are 4 3 tests that still fail with -Zinstrument-coverage
that I don't understand.
I'm hoping someone(s) that understand these tests and/or compiler options can take a look, explain why they are expected to fail, or clarify what the bug might be, if they should not fail.
Fixed via #80072
$ ./x.py test --rustc-args="-Zinstrument-coverage" src/test/ui/consts/unstable-precise-live-drops-in-libcore.rs
Failure due to:
error[E0493]: destructors cannot be evaluated at compile-time
--> /usr/local/google/home/richkadel/rust/src/test/ui/consts/unstable-precise-live-drops-in-libcore.rs:15:25
|
LL | pub const fn unwrap(self) -> T {
| ^^^^ constant functions cannot evaluate destructors
(this error is printed twice)
$ ./x.py test --rustc-args="-Zinstrument-coverage" src/test/ui/issues/issue-33287.rs
Failure due to:
stderr:
------------------------------------------
error: this operation will panic at runtime
--> /usr/local/google/home/richkadel/rust/src/test/ui/issues/issue-33287.rs:7:17
|
LL | let range = A[1]..;
| ^^^^ index out of bounds: the length is 1 but the index is 1
|
= note: `#[deny(unconditional_panic)]` on by default
$ ./x.py test --rustc-args="-Zinstrument-coverage" src/test/ui/print_type_sizes/niche-filling.rs
Failure due to additional lines in the compiler output:
+ print-type-size type: `std::option::Option<std::num::NonZeroU32>`: 4 bytes, alignment: 4 bytes
+ print-type-size variant `Some`: 4 bytes
+ print-type-size field `.0`: 4 bytes
+ print-type-size variant `None`: 0 bytes
$ ./x.py test --rustc-args="-Zinstrument-coverage" src/test/ui/trivial-bounds/trivial-bounds-inconsistent.rs
Failure due to:
error: internal compiler error:
compiler/rustc_traits/src/normalize_erasing_regions.rs:43:32:
could not fully normalize `std::option::Option<<i32 as std::iter::Iterator>::Item>`