Re:Fun facts about Rust's growing popularity
by cesarb on Monday October 30, 2017 @08:17AM
(#15584429)
Fun fact: what you did is a hand implementation of Rust's "drop flag" (https://doc.rust-lang.org/nomicon/drop-flags.html).
[ Parent
| on HN ]
Re:Fun facts about Rust's growing popularity
by Mouse47 on Monday October 30, 2017 @08:30AM
(#15584482)
That's pretty cool - it never occurred to me that determining drops required anything other than static analysis. Nice that it doesn't affect the layout of the types, either...which I'm guessing is why they added:
>The drop flags are tracked on the stack and no longer stashed in types that implement drop.