Use LocalDefId for closures more
This commit is contained in:
parent
1202bbaf48
commit
cf2433a74f
29 changed files with 164 additions and 171 deletions
|
@ -129,7 +129,7 @@ impl<'tcx> Visitor<'tcx> for UnsafetyChecker<'_, 'tcx> {
|
|||
}
|
||||
&AggregateKind::Closure(def_id, _) | &AggregateKind::Generator(def_id, _, _) => {
|
||||
let UnsafetyCheckResult { violations, used_unsafe_blocks, .. } =
|
||||
self.tcx.unsafety_check_result(def_id.expect_local());
|
||||
self.tcx.unsafety_check_result(def_id);
|
||||
self.register_violations(
|
||||
violations,
|
||||
used_unsafe_blocks.iter().map(|(&h, &d)| (h, d)),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue