@@ -1390,7 +1390,7 @@ pub struct StructExpr {
13901390// Adding a new variant? Please update `test_expr` in `tests/ui/macros/stringify.rs`.
13911391#[ derive( Clone , Encodable , Decodable , Debug ) ]
13921392pub enum ExprKind {
1393- /// An array (`[a, b, c, d]`)
1393+ /// An array (e.g, `[a, b, c, d]`).
13941394 Array ( ThinVec < P < Expr > > ) ,
13951395 /// Allow anonymous constants from an inline `const` block
13961396 ConstBlock ( AnonConst ) ,
@@ -1401,7 +1401,7 @@ pub enum ExprKind {
14011401 /// This also represents calling the constructor of
14021402 /// tuple-like ADTs such as tuple structs and enum variants.
14031403 Call ( P < Expr > , ThinVec < P < Expr > > ) ,
1404- /// A method call (e.g. `x.foo::<Bar, Baz>(a, b, c)`).
1404+ /// A method call (e.g., `x.foo::<Bar, Baz>(a, b, c)`).
14051405 MethodCall ( Box < MethodCall > ) ,
14061406 /// A tuple (e.g., `(a, b, c, d)`).
14071407 Tup ( ThinVec < P < Expr > > ) ,
@@ -1413,7 +1413,10 @@ pub enum ExprKind {
14131413 Lit ( token:: Lit ) ,
14141414 /// A cast (e.g., `foo as f64`).
14151415 Cast ( P < Expr > , P < Ty > ) ,
1416- /// A type ascription (e.g., `42: usize`).
1416+ /// A type ascription (e.g., `builtin # type_ascribe(42, usize)`).
1417+ ///
1418+ /// Usually not written directly in user code but
1419+ /// indirectly via the macro `type_ascribe!(...)`.
14171420 Type ( P < Expr > , P < Ty > ) ,
14181421 /// A `let pat = expr` expression that is only semantically allowed in the condition
14191422 /// of `if` / `while` expressions. (e.g., `if let 0 = x { .. }`).
@@ -1488,7 +1491,10 @@ pub enum ExprKind {
14881491 /// Output of the `asm!()` macro.
14891492 InlineAsm ( P < InlineAsm > ) ,
14901493
1491- /// Output of the `offset_of!()` macro.
1494+ /// An `offset_of` expression (e.g., `builtin # offset_of(Struct, field)`).
1495+ ///
1496+ /// Usually not written directly in user code but
1497+ /// indirectly via the macro `core::mem::offset_of!(...)`.
14921498 OffsetOf ( P < Ty > , P < [ Ident ] > ) ,
14931499
14941500 /// A macro invocation; pre-expansion.
0 commit comments