Crate boxext [] [src]

Extensions to the Box type

This crate provides extra initializer methods for Box, working around the current (as of writing) shortcomings from Box::new:

Both can be worked around with some contortion but with caveats. This crate provides helpers doing those contortions for you, but can't deal with the caveats. Those caveats are essentially the same as why the unstable placement features were removed in nightly 1.27, namely that there are no guarantees that things will actually happen in place (and they don't in debug builds).

The crates adds the following helper methods to the Box type:

Features

Traits

BoxExt

Extensions to the Box type

Zero

Trait indicating whether a value full of zeroes is valid.