mirror of
https://github.com/openharmony/third_party_rust_os_str_bytes.git
synced 2026-07-18 16:14:27 -04:00
17 lines
382 B
Rust
17 lines
382 B
Rust
#![allow(dead_code)]
|
|
#![cfg(feature = "raw_os_str")]
|
|
|
|
use std::mem;
|
|
|
|
use os_str_bytes::RawOsStr;
|
|
|
|
#[path = "common.rs"]
|
|
mod common;
|
|
use common::WTF8_STRING;
|
|
|
|
// SAFETY: This string is valid in WTF-8. This implementation detail can only
|
|
// be assumed by this crate.
|
|
#[cfg(any(unix, windows))]
|
|
pub(crate) const RAW_WTF8_STRING: &RawOsStr =
|
|
unsafe { mem::transmute(WTF8_STRING) };
|