Reference core library instead in examples

This commit is contained in:
Yota Toyama 2025-04-06 20:51:27 -07:00
parent eb085c5464
commit 424f5ab39c

View File

@ -28,8 +28,8 @@ impl<const N: usize> CString<N> {
/// Creates a new C-compatible string with a terminating nul byte.
///
/// ```rust
/// use core::ffi::CStr;
/// use heapless::CString;
/// use std::ffi::CStr;
///
/// // Fixed-size CString that can store up to 10 elements
/// // (counting the nul terminator)
@ -107,8 +107,8 @@ impl<const N: usize> CString<N> {
/// # Example
///
/// ```rust
/// use core::ffi::{c_char, CStr};
/// use heapless::CString;
/// use std::ffi::{c_char, CStr};
///
/// const HELLO_PTR: *const c_char = {
/// const BYTES: &[u8] = b"Hello, world!\0";