pub enum ParsedType {
Show 15 variants
I8(PassingStyle),
I16(PassingStyle),
I32(PassingStyle),
I64(PassingStyle),
U8(PassingStyle),
U16(PassingStyle),
U32(PassingStyle),
U64(PassingStyle),
F32(PassingStyle),
F64(PassingStyle),
Boolean(PassingStyle),
Utf8Str(PassingStyle),
Utf8String(PassingStyle),
Vector(Box<ParsedType>, PassingStyle),
Record(String, PassingStyle),
}
Expand description
An internal representation of supported Rust types.
Variants§
I8(PassingStyle)
I16(PassingStyle)
I32(PassingStyle)
I64(PassingStyle)
U8(PassingStyle)
U16(PassingStyle)
U32(PassingStyle)
U64(PassingStyle)
F32(PassingStyle)
F64(PassingStyle)
Boolean(PassingStyle)
Utf8Str(PassingStyle)
Utf8String(PassingStyle)
Vector(Box<ParsedType>, PassingStyle)
Record(String, PassingStyle)
Implementations§
Source§impl ParsedType
impl ParsedType
pub fn from_type(input_type: &Type) -> Result<Self>
pub fn from_fn_arg(fn_arg: &FnArg) -> Result<Self>
pub fn from_return_type(ret_type: &ReturnType) -> Result<Option<Self>>
pub fn is_complex_type(&self) -> bool
Trait Implementations§
Source§impl Clone for ParsedType
impl Clone for ParsedType
Source§fn clone(&self) -> ParsedType
fn clone(&self) -> ParsedType
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ParsedType
impl Debug for ParsedType
Source§impl<'de> Deserialize<'de> for ParsedType
impl<'de> Deserialize<'de> for ParsedType
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for ParsedType
impl Display for ParsedType
Source§impl PartialEq for ParsedType
impl PartialEq for ParsedType
Source§impl Serialize for ParsedType
impl Serialize for ParsedType
Source§impl ToTokens for ParsedType
impl ToTokens for ParsedType
Source§fn to_tokens(&self, tokens: &mut TokenStream)
fn to_tokens(&self, tokens: &mut TokenStream)
Source§fn to_token_stream(&self) -> TokenStream
fn to_token_stream(&self) -> TokenStream
Source§fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
impl StructuralPartialEq for ParsedType
Auto Trait Implementations§
impl Freeze for ParsedType
impl RefUnwindSafe for ParsedType
impl Send for ParsedType
impl Sync for ParsedType
impl Unpin for ParsedType
impl UnwindSafe for ParsedType
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,
Source§impl<T> Spanned for Twhere
T: Spanned + ?Sized,
impl<T> Spanned for Twhere
T: Spanned + ?Sized,
Source§fn span(&self) -> Span
fn span(&self) -> Span
Returns a
Span
covering the complete contents of this syntax tree
node, or Span::call_site()
if this node is empty.