Module rustc_middle::ty::closure
source · Structs§
- Part of
MinCaptureInformationMap; describes the capture kind (&, &mut, move) for a particular capture as well as identifying the part of the source code that triggered this capture to occur. - A composite describing a
Placethat is captured by a closure. - Upvars do not get their own
NodeId. Instead, we use the pair of the original var ID (that is, the root variable that is referenced by the upvar) and the ID of the closure expression.
Enums§
- Information describing the capture of an upvar. This is computed during
typeck, specifically byregionck.
Constants§
- Captures are represented using fields inside a structure. This represents accessing self in the closure structure
Functions§
- Return true if the
proj_possible_ancestorrepresents an ancestor path toproj_captureorproj_possible_ancestoris same asproj_capture, assuming they both start off of the same root variable.
Type Aliases§
- Given the closure DefId this map provides a map of root variables to minimum set of
CapturedPlaces that need to be tracked to support all captures of that closure. - Part of
MinCaptureInformationMap; List ofCapturePlaces. - Part of
MinCaptureInformationMap; Maps a root variable to the list ofCapturedPlace. Used to track the minimum set ofPlaces that need to be captured to support all Places captured by the closure starting at a given root variable.