8000 Trait size of number in bits · Issue #414 · rust-num/num · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Trait size of number in bits #414
Open
@Stargateur

Description

@Stargateur

I'm interest in having a trait that return the number of bits of T, std only have associated constant, u8::BITS. Similar to num::Bounded.

Alternative, let n_bits = std::mem::size_of::<T>() * u8::BITS as usize;.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0