#[repr(transparent)]pub struct SolIdent(pub Ident);
Expand description
A Solidity identifier.
Tuple Fields§
§0: Ident
Implementations§
Source§impl SolIdent
impl SolIdent
pub fn new(s: &str) -> Self
pub fn new_spanned(s: &str, span: Span) -> Self
Sourcepub fn as_string(&self) -> String
pub fn as_string(&self) -> String
Returns the identifier as a string, without the r#
prefix if present.
Sourcepub fn parse_any(input: ParseStream<'_>) -> Result<Self>
pub fn parse_any(input: ParseStream<'_>) -> Result<Self>
Parses any identifier including keywords.
Sourcepub fn peek_any(input: ParseStream<'_>) -> bool
pub fn peek_any(input: ParseStream<'_>) -> bool
Peeks any identifier including keywords.
pub fn parse_opt(input: ParseStream<'_>) -> Result<Option<Self>>
Trait Implementations§
Source§impl FromIterator<SolIdent> for SolPath
impl FromIterator<SolIdent> for SolPath
Source§impl IdentFragment for SolIdent
impl IdentFragment for SolIdent
Source§impl Ord for SolIdent
impl Ord for SolIdent
Source§impl PartialOrd for SolIdent
impl PartialOrd for SolIdent
Source§impl Spanned for SolIdent
impl Spanned for SolIdent
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.Source§impl ToTokens for SolIdent
impl ToTokens for SolIdent
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 Eq for SolIdent
impl StructuralPartialEq for SolIdent
Auto Trait Implementations§
impl Freeze for SolIdent
impl RefUnwindSafe for SolIdent
impl !Send for SolIdent
impl !Sync for SolIdent
impl Unpin for SolIdent
impl UnwindSafe for SolIdent
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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.