Extra Credit

ref-cast

Safely cast &T to &U where the struct U contains a single field of type T.

$cargo add ref-cast

Official docs outline

Extra Credit builds an outline of ref-cast's docs the first time your work uses it. Until then, start at the official documentation.

All 4,945