Open
Description
Feature gate: #![feature(c_str_module)]
This is a tracking issue for the std::ffi::c_str
module.
Public API
This adds {core, alloc, std}::ffi::c_str
modules and migrates some existing types into them. Types will still be re-exported in their current places to ensure compatibility.
The following migrations are made:
core::ffi::CStr
=>core::ffi::c_str::CStr
core::ffi::FromBytesUntilNulError
=>core::ffi::c_str::FromBytesUntilNulError
core::ffi::FromBytesWithNulError
=>core::ffi::c_str::FromBytesWithNulError
alloc::ffi::CString
=>alloc::ffi::c_str::CString
alloc::ffi::FromVecWIthNulError
=>alloc::ffi::c_str::FromVecWIthNulError
alloc::ffi::IntoStringError
=>alloc::ffi::c_str::IntoStringError
alloc::ffi::NulError
=>alloc::ffi::c_str::NulError
And these types are also migrated on the std
crate as well.
Steps / History
- API change proposal (ACP)1: ACP:
std::ffi::c
andstd::ffi::os
submodules libs-team#134 - Implementation: Add std::ffi::c_str module #112136
- Final comment period (FCP)2
- Stabilization PR
Unresolved Questions
- Should
c_str
andc_string
be separated? This was not discussed in the original ACP.
Footnotes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment