Stabilize Deserialize for Box<CStr>
This commit is contained in:
parent
1385aac208
commit
7ec3cac7d6
@ -33,6 +33,12 @@ fn main() {
|
|||||||
Err(_) => return,
|
Err(_) => return,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// CString::into_boxed_c_str stabilized in Rust 1.20:
|
||||||
|
// https://doc.rust-lang.org/std/ffi/struct.CString.html#method.into_boxed_c_str
|
||||||
|
if minor >= 20 {
|
||||||
|
println!("cargo:rustc-cfg=de_boxed_c_str");
|
||||||
|
}
|
||||||
|
|
||||||
// 128-bit integers stabilized in Rust 1.26:
|
// 128-bit integers stabilized in Rust 1.26:
|
||||||
// https://blog.rust-lang.org/2018/05/10/Rust-1.26.html
|
// https://blog.rust-lang.org/2018/05/10/Rust-1.26.html
|
||||||
if minor >= 26 {
|
if minor >= 26 {
|
||||||
|
@ -573,7 +573,7 @@ macro_rules! forwarded_impl {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(all(feature = "std", feature = "unstable"))]
|
#[cfg(all(feature = "std", de_boxed_c_str))]
|
||||||
forwarded_impl!((), Box<CStr>, CString::into_boxed_c_str);
|
forwarded_impl!((), Box<CStr>, CString::into_boxed_c_str);
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
Loading…
x
Reference in New Issue
Block a user