Skip to content

Commit 9ab8df9

Browse files
committed
Use fake libc in core test
1 parent 8c4d94a commit 9ab8df9

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

library/core/src/primitive_docs.rs

+4-3
Original file line numberDiff line numberDiff line change
@@ -537,9 +537,10 @@ impl () {}
537537
/// ## 4. Get it from C.
538538
///
539539
/// ```
540-
/// # #![feature(rustc_private)]
541-
/// #[allow(unused_extern_crates)]
542-
/// extern crate libc;
540+
/// # mod libc {
541+
/// # fn malloc(size: usize) -> *mut u8 { core::ptr::NonNull::dangling().as_ptr() }
542+
/// # fn free(mem: *mut u8) {}
543+
/// # }
543544
///
544545
/// use std::mem;
545546
///

0 commit comments

Comments
 (0)