mirror of
https://github.com/Astatin3/unshell.git
synced 2026-06-08 22:38:01 -06:00
Load ELF from memory using memfd_create
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
use std::collections::HashMap;
|
||||
use std::{collections::HashMap, fmt::Debug};
|
||||
|
||||
// use bincode::{Decode, Encode};
|
||||
// use serde::{Deserialize, Serialize};
|
||||
@@ -40,6 +40,16 @@ pub struct NamedComponent {
|
||||
),
|
||||
}
|
||||
|
||||
impl Debug for NamedComponent {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
f.debug_struct("NamedComponent")
|
||||
.field("name", &self.name)
|
||||
// .field("get_interface", &self.get_interface)
|
||||
// .field("start_runtime", &self.start_runtime)
|
||||
.finish()
|
||||
}
|
||||
}
|
||||
|
||||
/// Trait that wraps the get_interface<T>() function inside of components
|
||||
pub trait InterfaceWrapper: Send + Sync {
|
||||
fn get_interface<T: 'static>(&self) -> Option<T>
|
||||
|
||||
Reference in New Issue
Block a user