Skip to content

Commit

Permalink
struct definition before impl
Browse files Browse the repository at this point in the history
  • Loading branch information
bkarstens committed Sep 23, 2024
1 parent 41df679 commit 3231d56
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions AdvLoggerPkg/Crates/RustAdvancedLoggerDxe/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,14 +71,6 @@ struct AdvancedLoggerProtocolInterface {
write_log: AdvancedLoggerWriteProtocol,
}

impl Deref for AdvancedLoggerProtocol {
type Target = efi::Guid;

fn deref(&self) -> &Self::Target {
self.protocol_guid()
}
}

struct AdvancedLoggerProtocol;

unsafe impl Protocol for AdvancedLoggerProtocol {
Expand All @@ -88,6 +80,14 @@ unsafe impl Protocol for AdvancedLoggerProtocol {
}
}

impl Deref for AdvancedLoggerProtocol {
type Target = efi::Guid;

fn deref(&self) -> &Self::Target {
self.protocol_guid()
}
}

// Private un-synchronized AdvancedLogger wrapper. Provides implementation of fmt::Write for AdvancedLogger.
#[derive(Debug)]
struct AdvancedLogger {
Expand Down

0 comments on commit 3231d56

Please sign in to comment.