rust/compiler/rustc_typeck
Jubilee 7ade6ed48e
Rollup merge of #89208 - wesleywiser:rfc_2229_droporder, r=nikomatsakis
[rfc 2229] Drop fully captured upvars in the same order as the regular drop code

Currently, with the new 2021 edition, if a closure captures all of the
fields of an upvar, we'll drop those fields in the order they are used
within the closure instead of the normal drop order (the definition
order of the fields in the type).

This changes that so we sort the captured fields by the definition order
which causes them to drop in that same order as well.

Fixes rust-lang/project-rfc-2229#42

r? `@nikomatsakis`
2021-09-24 11:40:14 -07:00
..
src Rollup merge of #89208 - wesleywiser:rfc_2229_droporder, r=nikomatsakis 2021-09-24 11:40:14 -07:00
Cargo.toml Migrate to 2021 2021-09-20 22:21:42 -04:00
README.md

For high-level intro to how type checking works in rustc, see the type checking chapter of the rustc dev guide.