Skip to content

Use target pointer width rather than x86 #26

@tgross35

Description

@tgross35

The code

/// A word.
#[cfg(not(target_arch = "x86"))]
pub type Word = u64;
/// Doubled word.
#[cfg(not(target_arch = "x86"))]
pub type DoubleWord = u128;
/// Word with sign.
#[cfg(not(target_arch = "x86"))]
pub type SignedWord = i128;
/// A word.
#[cfg(target_arch = "x86")]
pub type Word = u32;
/// Doubled word.
#[cfg(target_arch = "x86")]
pub type DoubleWord = u64;
/// Word with sign.
#[cfg(target_arch = "x86")]
pub type SignedWord = i64;
has a lot of code that is configured based on x86 or not(x86). Is there a reason that x86 is special, or could this instead use #[cfg(target_pointer_width = 64)]/#[cfg(target_pointer_width = 32)]?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions