Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Corelib
Drop
pub trait Drop
struct Point { x: u128, y: u128, } fn foo(p: Point) {} // Error: `p` cannot be dropped
#[derive(Drop)] struct Point { x: u128, y: u128, } fn foo(p: Point) {} // OK: `p` is dropped at the end of the function
Was this page helpful?