Enum qasmsim::error::SemanticError
source · #[non_exhaustive]pub enum SemanticError {
RedefinitionError {
symbol_name: String,
location: Location,
previous_location: Location,
},
}
Expand description
Represent the possible semantic errors.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Trait Implementations§
source§impl Clone for SemanticError
impl Clone for SemanticError
source§fn clone(&self) -> SemanticError
fn clone(&self) -> SemanticError
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 SemanticError
impl Debug for SemanticError
source§impl Display for SemanticError
impl Display for SemanticError
source§impl Error for SemanticError
impl Error for SemanticError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<SemanticError> for RuntimeError
impl From<SemanticError> for RuntimeError
source§fn from(semantic_error: SemanticError) -> Self
fn from(semantic_error: SemanticError) -> Self
Converts to this type from the input type.
source§impl Hash for SemanticError
impl Hash for SemanticError
source§impl PartialEq for SemanticError
impl PartialEq for SemanticError
source§fn eq(&self, other: &SemanticError) -> bool
fn eq(&self, other: &SemanticError) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for SemanticError
impl StructuralEq for SemanticError
impl StructuralPartialEq for SemanticError
Auto Trait Implementations§
impl RefUnwindSafe for SemanticError
impl Send for SemanticError
impl Sync for SemanticError
impl Unpin for SemanticError
impl UnwindSafe for SemanticError
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