mirror of
https://github.com/qemu/qemu.git
synced 2025-08-16 06:43:21 +00:00
rust: fix doc test syntax
Allow "cargo test --doc" to pass. Reviewed-by: Junjie Mao <junjie.mao@hotmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
4e0a11d12f
commit
8a88b55f69
@ -7,9 +7,9 @@
|
||||
/// behavior. This trait in principle could be implemented as just:
|
||||
///
|
||||
/// ```
|
||||
/// const ZERO: Self = unsafe {
|
||||
/// ::core::mem::MaybeUninit::<$crate::bindings::Property>::zeroed().assume_init()
|
||||
/// },
|
||||
/// pub unsafe trait Zeroable: Default {
|
||||
/// const ZERO: Self = unsafe { ::core::mem::MaybeUninit::<Self>::zeroed().assume_init() };
|
||||
/// }
|
||||
/// ```
|
||||
///
|
||||
/// The need for a manual implementation is only because `zeroed()` cannot
|
||||
|
Loading…
Reference in New Issue
Block a user