We have previously tried to import traits anonymously where possible but
enforcing this manually was hard.
Since Rust 1.83 clippy can now enforce this for us.
Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
Change FromRawTracepointArgs::arg to return T rather than *const T which
seems to have been returning a dangling pointer.
Arguably this is not strictly necessary; edition 2024 seems to be
focused on increased strictness around unsafe code which doesn't unlock
new functionality for our users. That said, this work revealed an
apparent bug (see above) that we wouldn't otherwise catch due to
allow-by-default lints.
The const-assert crate doesn't even compile with stable rust, so we
shouldn't depend on it. Instead we replicate its functionality behind
cfg(unstable) which is set at build time based on the toolchain in use.
This API doesn't make sense as the max_entries needs to be set to the
number of online CPUs by the loader.
Signed-off-by: Dave Tucker <dave@dtucker.co.uk>