fwd/vendor/cxx/tests/unique_ptr.rs
John Doty 9c435dc440 Vendor dependencies
Let's see how I like this workflow.
2022-12-19 08:38:22 -08:00

10 lines
261 B
Rust

#![allow(clippy::let_underscore_drop)]
use cxx::{CxxString, UniquePtr};
#[test]
#[should_panic = "called deref on a null UniquePtr<CxxString>"]
fn test_deref_null() {
let unique_ptr = UniquePtr::<CxxString>::null();
let _: &CxxString = &unique_ptr;
}