-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
1.95 beta regression: "temporary value dropped while borrowed" #153850
Copy link
Copy link
Closed
Labels
A-destructorsArea: Destructors (`Drop`, …)Area: Destructors (`Drop`, …)A-fmtArea: `core::fmt`Area: `core::fmt`A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)A-temporary-lifetime-extensionArea: temporary lifetime extensionArea: temporary lifetime extensionC-bugCategory: This is a bug.Category: This is a bug.P-highHigh priorityHigh priorityS-has-bisectionStatus: A bisection has been found for this issueStatus: A bisection has been found for this issueS-has-mcveStatus: A Minimal Complete and Verifiable Example has been found for this issueStatus: A Minimal Complete and Verifiable Example has been found for this issueT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.Performance or correctness regression from stable to beta.
Milestone
Description
Regression found by the 1.95 beta crater run.
[INFO] [stdout] error[E0716]: temporary value dropped while borrowed
[INFO] [stdout] --> src/lib.rs:229:34
[INFO] [stdout] |
[INFO] [stdout] 227 | // ... dbg!(
[INFO] [stdout] 228 | || ... x.value().score / x.value().playouts as f32,
[INFO] [stdout] 229 | || ... &x.id(),
[INFO] [stdout] | || ^^^^^^ creates a temporary value which is freed while still in use
[INFO] [stdout] 230 | || ... x.value().playouts,
[INFO] [stdout] 231 | || ... )
[INFO] [stdout] | ||_______________________- temporary value is freed at the end of this statement
[INFO] [stdout] 232 | | ... .0,
[INFO] [stdout] | |_________________________- borrow later used here
[INFO] [stdout] |
[INFO] [stdout] = note: consider using a `let` binding to create a longer lived value
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stderr] error: could not compile `monte_carlo` (lib) due to 1 previous error; 2 warnings emitted
[INFO] [stdout] For more information about this error, try `rustc --explain E0716`.
https://crater-reports.s3.amazonaws.com/beta-1.95-3/1.95.0-beta.3/reg/monte_carlo-0.1.1/log.txt
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
A-destructorsArea: Destructors (`Drop`, …)Area: Destructors (`Drop`, …)A-fmtArea: `core::fmt`Area: `core::fmt`A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)A-temporary-lifetime-extensionArea: temporary lifetime extensionArea: temporary lifetime extensionC-bugCategory: This is a bug.Category: This is a bug.P-highHigh priorityHigh priorityS-has-bisectionStatus: A bisection has been found for this issueStatus: A bisection has been found for this issueS-has-mcveStatus: A Minimal Complete and Verifiable Example has been found for this issueStatus: A Minimal Complete and Verifiable Example has been found for this issueT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.Performance or correctness regression from stable to beta.
Type
Fields
Give feedbackNo fields configured for issues without a type.