diff options
author | iximeow <me@iximeow.net> | 2019-08-06 20:52:04 -0700 |
---|---|---|
committer | iximeow <me@iximeow.net> | 2020-01-12 17:28:07 -0800 |
commit | 22f9afd31c902ded123f175a95812955c965233f (patch) | |
tree | c699732ff31edb469e6979b69c619d01f59ee3bf /src/armv8/a64.rs | |
parent | 77bc926bb3b0840bc91dd0774d01e8ca25c80616 (diff) |
armv8 serde/no-serde support plus contextual display .. ish
Diffstat (limited to 'src/armv8/a64.rs')
-rw-r--r-- | src/armv8/a64.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/armv8/a64.rs b/src/armv8/a64.rs index d640292..e58d2a2 100644 --- a/src/armv8/a64.rs +++ b/src/armv8/a64.rs @@ -116,6 +116,18 @@ mod docs { } } +#[allow(non_snake_case)] +impl <T: std::fmt::Write> ShowContextual<u64, [Option<String>], T> for Instruction { + fn contextualize(&self, colors: Option<&ColorSettings>, address: u64, context: Option<&[Option<String>]>, out: &mut T) -> std::fmt::Result { + write!(out, "{}", self) + } +} + +#[cfg(feature="use-serde")] +#[derive(Copy, Clone, Debug, Serialize, Deserialize)] +pub struct ARMv8 { } + +#[cfg(not(feature="use-serde"))] #[derive(Copy, Clone, Debug)] pub struct ARMv8 { } |