[PATCH v5 3/6] rust: enable `clippy::ptr_cast_constness` lint