Skip to content

Commit

Permalink
Try using lookup_stability instead
Browse files Browse the repository at this point in the history
  • Loading branch information
camelid committed Jul 22, 2021
1 parent a84656e commit b318344
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compiler/rustc_passes/src/stability.rs
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@ impl<'tcx> MissingStabilityAnnotations<'tcx> {
}

fn check_private_stability(&self, hir_id: HirId, span: Span) {
let stab = self.tcx.stability().local_stability(hir_id);
let stab = self.tcx.lookup_stability(self.tcx.hir().local_def_id(hir_id));
let is_error = stab.is_some() && !self.access_levels.is_reachable(hir_id);
if is_error {
let def_id = self.tcx.hir().local_def_id(hir_id);
Expand Down

0 comments on commit b318344

Please sign in to comment.