]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc/ty/context.rs
Allow for re-using hidden monomorphizations on platforms that don't support Rust...
[rust.git] / src / librustc / ty / context.rs
index 3e6002cbd51717eed89acfba42a5166bee8e2fc0..69b33efdb3542c02bace3f32fb00ac3560ef3498 100644 (file)
@@ -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 |