pub struct Method {
pub name: String,
pub instructions: Vec<Instruction>,
pub span: Range<usize>,
}Expand description
方法定义
Fields§
§name: String§instructions: Vec<Instruction>§span: Range<usize>Trait Implementations§
Source§impl AsDocument for Method
Available on crate feature oak-pretty-print only.
impl AsDocument for Method
Available on crate feature
oak-pretty-print only.Source§fn as_document(&self) -> Document<'_>
fn as_document(&self) -> Document<'_>
Converts this type to a document for pretty printing.
Source§impl<'de> Deserialize<'de> for Method
impl<'de> Deserialize<'de> for Method
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Method, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Method, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for Method
impl Serialize for Method
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl ToSource for Method
impl ToSource for Method
Source§fn to_source(&self, buffer: &mut SourceBuffer)
fn to_source(&self, buffer: &mut SourceBuffer)
Writes the source code representation of this type to the provided buffer.
Source§fn to_source_string(&self) -> String
fn to_source_string(&self) -> String
Converts this type to a source code string.
impl Eq for Method
impl StructuralPartialEq for Method
Auto Trait Implementations§
impl Freeze for Method
impl RefUnwindSafe for Method
impl Send for Method
impl Sync for Method
impl Unpin for Method
impl UnwindSafe for Method
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