pub struct Snippet {
pub lang: String,
pub tags: Vec<String>,
pub body: String,
}Expand description
A fenced code block extracted from an error’s doc comment.
Fields§
§lang: StringThe info-string’s language token (the first comma-separated
segment): ebp, rust, lua, etc.
Bare (non-key=value) tags in the info-string, e.g. "fix" in
```ebp,code=EBP001,fix. Preserved in source order.
body: StringThe fence body, joined with \n and without the surrounding
``` lines.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Snippet
impl RefUnwindSafe for Snippet
impl Send for Snippet
impl Sync for Snippet
impl Unpin for Snippet
impl UnsafeUnpin for Snippet
impl UnwindSafe for Snippet
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