aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
authoriximeow <me@iximeow.net>2026-09-19 16:08:35 +0000
committeriximeow <me@iximeow.net>2026-09-19 16:08:35 +0000
commit41a2e8a8c02ce6c1461f405e151194bb4554d817 (patch)
tree69d56785312caed614734479535cea7d3e3ea645 /src/lib.rs
parent4b05ae977975edca88c4efbaa0df10330e2d7b7f (diff)
instruction alias trait
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs
index a0c237b..856e9cc 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -237,6 +237,11 @@ pub trait Instruction {
fn well_defined(&self) -> bool;
}
+pub trait InstructionAlias<I: Instruction>: LengthedInstruction {
+ fn compute_alias(t: &I) -> Self;
+ fn dealias(&self) -> I;
+}
+
#[allow(deprecated)]
#[deprecated(since="0.3.0", note="ShowContextual ties YaxColors and fmt::Write in a way that only sometimes composes. simultaneously, it is too generic on Ctx, making it difficult to implement and use. it will be revisited in the future.")]
pub trait ShowContextual<Addr, Ctx: ?Sized, T: fmt::Write, Y: YaxColors> {