3 releases

Uses old Rust 2015

0.1.2 Apr 11, 2016
0.1.1 Jan 15, 2016
0.1.0 Jan 14, 2016

#8 in #destructor

Download history 664/week @ 2024-03-14 603/week @ 2024-03-21 558/week @ 2024-03-28 649/week @ 2024-04-04 639/week @ 2024-04-11 453/week @ 2024-04-18 576/week @ 2024-04-25 578/week @ 2024-05-02 388/week @ 2024-05-09 503/week @ 2024-05-16 609/week @ 2024-05-23 501/week @ 2024-05-30 409/week @ 2024-06-06 632/week @ 2024-06-13 950/week @ 2024-06-20 642/week @ 2024-06-27

2,714 downloads per month
Used in 24 crates (2 directly)

Apache-2.0 OR MIT

4KB
94 lines

Leak a piece of data by never calling its destructor

Useful for things that are going to be used for the life of the program, but aren't technically static (because they are created in response to arguments, environment, or other configuration/data read at program start).

This is a modified version of the proposed rfc: https://github.com/rust-lang/rfcs/pull/1233

Notable changes:

  • for convenience, leak() is a non-static method

No runtime deps