Enum solang_parser::pt::PragmaDirective
source · pub enum PragmaDirective {
Identifier(Loc, Option<Identifier>, Option<Identifier>),
StringLiteral(Loc, Identifier, StringLiteral),
Version(Loc, Identifier, Vec<VersionComparator>),
}
Expand description
A pragma directive
Variants§
Identifier(Loc, Option<Identifier>, Option<Identifier>)
pragma a b;
StringLiteral(Loc, Identifier, StringLiteral)
pragma a “b”;
Version(Loc, Identifier, Vec<VersionComparator>)
pragma version =0.5.16;
Trait Implementations§
source§impl Clone for PragmaDirective
impl Clone for PragmaDirective
source§fn clone(&self) -> PragmaDirective
fn clone(&self) -> PragmaDirective
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 CodeLocation for PragmaDirective
impl CodeLocation for PragmaDirective
source§impl Debug for PragmaDirective
impl Debug for PragmaDirective
source§impl Display for PragmaDirective
impl Display for PragmaDirective
source§impl PartialEq for PragmaDirective
impl PartialEq for PragmaDirective
source§fn eq(&self, other: &PragmaDirective) -> bool
fn eq(&self, other: &PragmaDirective) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for PragmaDirective
impl StructuralPartialEq for PragmaDirective
Auto Trait Implementations§
impl Freeze for PragmaDirective
impl RefUnwindSafe for PragmaDirective
impl Send for PragmaDirective
impl Sync for PragmaDirective
impl Unpin for PragmaDirective
impl UnwindSafe for PragmaDirective
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> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more