-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
Unexplained errors applying -Z instrument-coverage to some rustc ui tests #80045
Copy link
Copy link
Open
Labels
A-code-coverageArea: Source-based code coverage (-Cinstrument-coverage)Area: Source-based code coverage (-Cinstrument-coverage)A-testsuiteArea: The testsuite used to check the correctness of rustcArea: The testsuite used to check the correctness of rustcC-bugCategory: This is a bug.Category: This is a bug.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-code-coverageArea: Source-based code coverage (-Cinstrument-coverage)Area: Source-based code coverage (-Cinstrument-coverage)A-testsuiteArea: The testsuite used to check the correctness of rustcArea: The testsuite used to check the correctness of rustcC-bugCategory: This is a bug.Category: This is a bug.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
When experimentally adding
-Zinstrument-coverageto the set ofuitests 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-coverageand other compiler options (see #79958 (comment)).However, there are
43 tests that still fail with-Zinstrument-coveragethat 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.rsFailure 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)