Skip to main content

devela/code/marker/
repr.rs

1// devela::code::marker::repr
2//
3//! Defines [`Repr`].
4//
5
6#[doc = crate::_tags!(code data)]
7/// Selects how a value exposes one of its representations.
8#[doc = crate::_doc_meta!{location("code/marker")}]
9#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, PartialOrd, Ord, Hash)]
10pub enum ReprMode {
11    /// Shows the direct underlying representation.
12    #[default]
13    Raw,
14    /// Shows named semantic parts when available.
15    Named,
16    /// Shows both the direct representation and named semantic parts.
17    RawNamed,
18}
19crate::_impl_init![Self::Raw => ReprMode];
20impl crate::BitSized<3> for ReprMode {}