pub struct Malformed {
pub tool: Tool,
pub kind: MalformedKind,
pub range: TextRange,
pub word: String,
}Expand description
A comment that announced itself as a directive but does not parse as one.
Recorded rather than dropped: a directive’s failure mode is that nothing happens, which is also what success looks like, so a malformed one has to be reported or it fails silently.
Fields§
§tool: Tool§kind: MalformedKind§range: TextRangeThe offending word, or the whole prefix when nothing followed it.
word: StringThe offending word as written.
Trait Implementations§
impl Eq for Malformed
impl StructuralPartialEq for Malformed
Auto Trait Implementations§
impl Freeze for Malformed
impl RefUnwindSafe for Malformed
impl Send for Malformed
impl Sync for Malformed
impl Unpin for Malformed
impl UnsafeUnpin for Malformed
impl UnwindSafe for Malformed
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