@@ -17,13 +17,13 @@ use rustc_target::abi::VariantIdx;
17
17
HashStable
18
18
) ]
19
19
pub enum PlaceBase {
20
- /// A temporary variable
20
+ /// A temporary variable.
21
21
Rvalue ,
22
- /// A named `static` item
22
+ /// A named `static` item.
23
23
StaticItem ,
24
- /// A named local variable
24
+ /// A named local variable.
25
25
Local ( HirId ) ,
26
- /// An upvar referenced by closure env
26
+ /// An upvar referenced by closure env.
27
27
Upvar ( ty:: UpvarId ) ,
28
28
}
29
29
@@ -40,7 +40,7 @@ pub enum PlaceBase {
40
40
HashStable
41
41
) ]
42
42
pub enum ProjectionKind {
43
- /// A dereference of a pointer, reference or `Box<T>` of the given type
43
+ /// A dereference of a pointer, reference or `Box<T>` of the given type.
44
44
Deref ,
45
45
46
46
/// `B.F` where `B` is the base expression and `F` is
@@ -71,16 +71,16 @@ pub enum ProjectionKind {
71
71
HashStable
72
72
) ]
73
73
pub struct Projection < ' tcx > {
74
- /// Type after the projection is being applied.
74
+ /// Type after the projection is applied.
75
75
pub ty : Ty < ' tcx > ,
76
76
77
- /// Defines the type of access
77
+ /// Defines the kind of access made by the projection.
78
78
pub kind : ProjectionKind ,
79
79
}
80
80
81
81
/// A `Place` represents how a value is located in memory.
82
82
///
83
- /// This is an HIR version of ` mir::Place`
83
+ /// This is an HIR version of [`rustc_middle:: mir::Place`].
84
84
#[ derive( Clone , Debug , PartialEq , Eq , Hash , TyEncodable , TyDecodable , TypeFoldable , HashStable ) ]
85
85
pub struct Place < ' tcx > {
86
86
/// The type of the `PlaceBase`
@@ -93,13 +93,13 @@ pub struct Place<'tcx> {
93
93
94
94
/// A `PlaceWithHirId` represents how a value is located in memory.
95
95
///
96
- /// This is an HIR version of ` mir::Place`
96
+ /// This is an HIR version of [`rustc_middle:: mir::Place`].
97
97
#[ derive( Clone , Debug , PartialEq , Eq , Hash , TyEncodable , TyDecodable , TypeFoldable , HashStable ) ]
98
98
pub struct PlaceWithHirId < ' tcx > {
99
99
/// `HirId` of the expression or pattern producing this value.
100
100
pub hir_id : HirId ,
101
101
102
- /// Information about the `Place`
102
+ /// Information about the `Place`.
103
103
pub place : Place < ' tcx > ,
104
104
}
105
105
0 commit comments