hir::ExprKind::InlineAsm(asm) => {
for (op, _op_sp) in asm.operands {
match op {
- hir::InlineAsmOperand::In { expr, .. }
- | hir::InlineAsmOperand::Sym { expr, .. } => self.consume_expr(expr),
+ hir::InlineAsmOperand::In { expr, .. } => self.consume_expr(expr),
hir::InlineAsmOperand::Out { expr: Some(expr), .. }
| hir::InlineAsmOperand::InOut { expr, .. } => {
self.mutate_expr(expr);
}
}
hir::InlineAsmOperand::Out { expr: None, .. }
- | hir::InlineAsmOperand::Const { .. } => {}
+ | hir::InlineAsmOperand::Const { .. }
+ | hir::InlineAsmOperand::SymFn { .. }
+ | hir::InlineAsmOperand::SymStatic { .. } => {}
}
}
}
/// In the following example the closures `c` only captures `p.x` even though `incr`
/// is a capture of the nested closure
///
- /// ```rust,ignore(cannot-test-this-because-pseudo-code)
- /// let p = ..;
+ /// ```
+ /// struct P { x: i32 }
+ /// let mut p = P { x: 4 };
/// let c = || {
/// let incr = 10;
/// let nested = || p.x += incr;
- /// }
+ /// };
/// ```
///
/// - When reporting the Place back to the Delegate, ensure that the UpvarId uses the enclosing