X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Flibrustc%2Fty%2Fcontext.rs;h=69b33efdb3542c02bace3f32fb00ac3560ef3498;hb=07704a4e1dd5c1b21e0a447d88511d455497b390;hp=3e6002cbd51717eed89acfba42a5166bee8e2fc0;hpb=ec55390387ac068184ded9283aece14aab9bfaf8;p=rust.git diff --git a/src/librustc/ty/context.rs b/src/librustc/ty/context.rs index 3e6002cbd51..69b33efdb35 100644 --- a/src/librustc/ty/context.rs +++ b/src/librustc/ty/context.rs @@ -1521,6 +1521,8 @@ pub fn share_generics(self) -> bool { #[inline] pub fn local_crate_exports_generics(self) -> bool { + debug_assert!(self.share_generics()); + self.sess.crate_types.borrow().iter().any(|crate_type| { match crate_type { CrateTypeExecutable |