Struct rustfmt_nightly::shape::Indent
source · Fields
block_indent: usize
alignment: usize
Implementations
sourceimpl Indent
impl Indent
pub(crate) fn new(block_indent: usize, alignment: usize) -> Indent
pub(crate) fn from_width(config: &Config, width: usize) -> Indent
pub(crate) fn empty() -> Indent
pub(crate) fn block_only(&self) -> Indent
pub(crate) fn block_indent(self, config: &Config) -> Indent
pub(crate) fn block_unindent(self, config: &Config) -> Indent
pub(crate) fn width(&self) -> usize
pub(crate) fn to_string(&self, config: &Config) -> Cow<'static, str>
pub(crate) fn to_string_with_newline(&self, config: &Config) -> Cow<'static, str>
fn to_string_inner(&self, config: &Config, offset: usize) -> Cow<'static, str>
Trait Implementations
impl Copy for Indent
Auto Trait Implementations
impl RefUnwindSafe for Indent
impl Send for Indent
impl Sync for Indent
impl Unpin for Indent
impl UnwindSafe for Indent
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Layout
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.
Size: 16 bytes