Function new_cstr
Source pub const fn new_cstr(s: &'static str) -> &'static CStr
Expand description
Create str to Cstr at compile time.
§Example
const HELLO: &std::ffi::CStr = commonlibsse_ng::skse::interfaces::new_cstr(concat!("hello", "\0"));
§Panics
This function panics if:
- The input string contains null bytes before the null terminator.
- The input string is not null-terminated.