# [−][src]Module typenum::marker_traits

All of the marker traits used in typenum.

Note that the definition here for marker traits is slightly different than the conventional one -- we include traits with functions that convert a type to the corresponding value, as well as associated constants that do the same.

For example, the `Integer` trait includes the function (among others) `fn to_i32() -> i32` and the associated constant `I32` so that one can do this:

    use typenum::{N42, Integer};

    assert_eq!(-42, N42::to_i32());
    assert_eq!(-42, N42::I32);

## Traits

Bit | The marker trait for compile time bits.
Integer | The marker trait for compile time signed integers.
NonZero | A marker trait to designate that a type is not zero. All number types in this crate implement `NonZero` except `B0`, `U0`, and `Z0`.
Ord | A Marker trait for the types `Greater`, `Equal`, and `Less`.
PowerOfTwo | The marker trait for type-level numbers which are a power of two.
TypeArray | The marker trait for type-level arrays of type-level numbers.
Unsigned | The marker trait for compile time unsigned integers.

# Help

## Keyboard Shortcuts

`?`
  Show this help dialog
`S`
  Focus the search field
`↑`
  Move up in search results
`↓`
  Move down in search results
`↹`
  Switch tab
`⏎`
  Go to active search result
`+`
  Expand all sections
`-`
  Collapse all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g., `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g., `vec -> usize` or `* -> vec`)

Search multiple things at once by splitting your query with comma (e.g., `str,u8` or `String,struct:Vec,test`)