aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
authoriximeow <me@iximeow.net>2026-02-14 18:33:39 +0000
committeriximeow <me@iximeow.net>2026-02-14 18:33:39 +0000
commitb7de8016c51f8d48bb3f91eb6d7be191d6b46d55 (patch)
tree6f9ca49ac868444563446394f8aa84777be770da /src/lib.rs
parentd12452b098f90e214e8be0b638b7faea42f42b24 (diff)
type aliases make some of these signatures less egregious..
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 43ff634..aea4c91 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -131,6 +131,14 @@ extern crate alloc;
#[macro_use]
mod isa_settings;
+// you'd hope that if Arch: yaxpeax_arch::Arch you could write Arch::Address and only mention the
+// trait if there were ambiguous definitions of Address on different traits. unfortunately:
+// https://github.com/rust-lang/rust/issues/38078
+//
+// these should probably go over to yaxpeax_arch 'cause they show up everywhere.
+type Address<Arch> = <Arch as yaxpeax_arch::Arch>::Address;
+type Word<Arch> = <Arch as yaxpeax_arch::Arch>::Word;
+
pub mod long_mode;
pub use long_mode as amd64;
pub use long_mode::Arch as x86_64;