-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-MIRArea: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.htmlArea: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.htmlT-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.
Description
As @eddyb noted on IRC:
15:04 <eddyb> this is weird: http://is.gd/Zjyjmd - it's dropping the outermost temporary, then the innermost, then the middle - shouldn't it be inside-out? or outside-in?
15:04 <eddyb> old trans appears to call them outside-in
15:04 <eddyb> and this drops x before foo(&x) http://is.gd/P1ergF
Related test:
src/test/run-pass/issue-23338-ensure-param-drop-order.rs
Metadata
Metadata
Assignees
Labels
A-MIRArea: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.htmlArea: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.htmlT-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.