pub enum FormatOutcome {
Edits(Vec<TextEdit>),
NoProvider {
is_range: bool,
},
}Expand description
Outcome of a :format / :format-range request. Drained
per frame; the App applies the edits as one undo unit or
echoes the appropriate failure / no-op state.
Variants§
Edits(Vec<TextEdit>)
Server returned a (possibly empty) edit list. Empty == no changes needed; non-empty == apply.
NoProvider
No attached server advertises the relevant formatting
provider (is_range distinguishes whole-buffer from
range-format providers since they’re separate caps).
Trait Implementations§
Source§impl Clone for FormatOutcome
impl Clone for FormatOutcome
Source§fn clone(&self) -> FormatOutcome
fn clone(&self) -> FormatOutcome
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for FormatOutcome
impl RefUnwindSafe for FormatOutcome
impl Send for FormatOutcome
impl Sync for FormatOutcome
impl Unpin for FormatOutcome
impl UnsafeUnpin for FormatOutcome
impl UnwindSafe for FormatOutcome
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more