diff options
| author | kennytm <kennytm@gmail.com> | 2018-08-04 14:35:55 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-08-04 14:35:55 +0800 |
| commit | d028b3ea338ccb1daa7780d69eb079eed39d8f5c (patch) | |
| tree | 846c774163e632a748c00f8c120922239c558dda | |
| parent | 035db4b00482806e5e037bd79d37fd326250bd62 (diff) | |
| parent | 6a3dfa4dba2d341b9d93481c3ccf8338248b5d20 (diff) | |
| download | rust-d028b3ea338ccb1daa7780d69eb079eed39d8f5c.tar.gz rust-d028b3ea338ccb1daa7780d69eb079eed39d8f5c.zip | |
Rollup merge of #53001 - petrochenkov:master, r=estebank
privacy: Fix an ICE in `path_is_private_type` Fixes https://github.com/rust-lang/rust/issues/52879 (Untested.)
| -rw-r--r-- | src/librustc_privacy/lib.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_privacy/lib.rs b/src/librustc_privacy/lib.rs index 405952065da..5c3a016a82b 100644 --- a/src/librustc_privacy/lib.rs +++ b/src/librustc_privacy/lib.rs @@ -1015,7 +1015,7 @@ struct ObsoleteCheckTypeForPrivatenessVisitor<'a, 'b: 'a, 'tcx: 'b> { impl<'a, 'tcx> ObsoleteVisiblePrivateTypesVisitor<'a, 'tcx> { fn path_is_private_type(&self, path: &hir::Path) -> bool { let did = match path.def { - Def::PrimTy(..) | Def::SelfTy(..) => return false, + Def::PrimTy(..) | Def::SelfTy(..) | Def::Err => return false, def => def.def_id(), }; |
