rust/tests/ui/feature-gates/feature-gate-derive-smart-pointer.rs
Xiangfei Ding f1be59fa72
SmartPointer derive-macro
Co-authored-by: Wedson Almeida Filho <walmeida@microsoft.com>
2024-06-24 03:03:34 +08:00

10 lines
332 B
Rust

use std::marker::SmartPointer; //~ ERROR use of unstable library feature 'derive_smart_pointer'
#[derive(SmartPointer)] //~ ERROR use of unstable library feature 'derive_smart_pointer'
struct MyPointer<'a, #[pointee] T: ?Sized> {
//~^ ERROR the `#[pointee]` attribute is an experimental feature
ptr: &'a T,
}
fn main() {}