mirror of
https://github.com/rust-osdev/uefi-rs
synced 2026-08-26 18:26:05 -04:00
uefi: Add more derives for Handle and Event
This commit is contained in:
parent
df210173b3
commit
c300c68ae4
2 changed files with 3 additions and 2 deletions
|
|
@ -3,6 +3,7 @@
|
|||
## Added
|
||||
- Added `Timestamp` protocol.
|
||||
- Added `UnalignedSlice::as_ptr`.
|
||||
- Added common derives for `Event` and `Handle`.
|
||||
|
||||
# uefi - 0.27.0 (2024-03-17)
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ use core::ptr::{self, NonNull};
|
|||
/// Opaque handle to an UEFI entity (protocol, image...), guaranteed to be non-null.
|
||||
///
|
||||
/// If you need to have a nullable handle (for a custom UEFI FFI for example) use `Option<Handle>`.
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
|
||||
#[derive(Clone, Copy, Debug, Hash, Eq, PartialEq, Ord, PartialOrd)]
|
||||
#[repr(transparent)]
|
||||
pub struct Handle(NonNull<c_void>);
|
||||
|
||||
|
|
@ -51,8 +51,8 @@ impl Handle {
|
|||
/// Handle to an event structure, guaranteed to be non-null.
|
||||
///
|
||||
/// If you need to have a nullable event, use `Option<Event>`.
|
||||
#[derive(Debug, Eq, PartialEq, Hash, Ord, PartialOrd)]
|
||||
#[repr(transparent)]
|
||||
#[derive(Debug)]
|
||||
pub struct Event(NonNull<c_void>);
|
||||
|
||||
impl Event {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue