Skip to content

Tracking Issue for nonzero_bitwise #128281

Open
@pitaj

Description

Feature gate: #![feature(nonzero_bitwise)]
ACP: rust-lang/libs-team#413

This is a tracking issue for bitwise and bytewise methods on NonZero. When used on a non-zero integer, these methods result in a non-zero integer, so can take the form fn(self) -> Self.

Public API

// core::num

impl<T> NonZero<T> {
    pub fn reverse_bits(self)  -> Self;
    pub fn rotate_left(self) -> Self;
    pub fn rotate_right(self) -> Self;
    pub fn swap_bytes(self) -> Self;
    pub fn to_be(self) -> Self;
    pub fn to_le(self) -> Self;
    pub fn from_be(x: Self) -> Self;
    pub fn from_le(x: Self) -> Self;
}

Steps / History

Unresolved Questions

  • None yet.

Footnotes

  1. https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions