pub struct FunctionSpan {
pub name: Option<String>,
pub start_line: usize,
pub end_line: usize,
}Expand description
Function span data.
Fields§
§name: Option<String>The function name, or None when the name could not be
resolved from the AST. Mirrors the Option<String> name
convention used by crate::FuncSpace and crate::ops::Ops.
start_line: usizeThe first line of a function
end_line: usizeThe last line of a function
Implementations§
Source§impl FunctionSpan
impl FunctionSpan
Sourcepub fn to_wire(&self) -> FunctionSpan
pub fn to_wire(&self) -> FunctionSpan
Project this span into its crate::wire::FunctionSpan form —
the plain, Deserialize-capable record that defines the serialized
shape.
Trait Implementations§
Source§impl Debug for FunctionSpan
impl Debug for FunctionSpan
Source§impl From<&FunctionSpan> for FunctionSpan
impl From<&FunctionSpan> for FunctionSpan
Source§fn from(f: &FunctionSpan) -> Self
fn from(f: &FunctionSpan) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for FunctionSpan
impl RefUnwindSafe for FunctionSpan
impl Send for FunctionSpan
impl Sync for FunctionSpan
impl Unpin for FunctionSpan
impl UnsafeUnpin for FunctionSpan
impl UnwindSafe for FunctionSpan
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