Struct etk_ops::shanghai::Difficulty
source · pub struct Difficulty;
Expand description
Representation of the difficulty
instruction.
Trait Implementations§
source§impl Clone for Difficulty
impl Clone for Difficulty
source§fn clone(&self) -> Difficulty
fn clone(&self) -> Difficulty
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 Difficulty
impl Debug for Difficulty
source§impl<T> From<Difficulty> for Op<T>where
T: ?Sized + Immediates,
impl<T> From<Difficulty> for Op<T>where T: ?Sized + Immediates,
source§fn from(op: Difficulty) -> Self
fn from(op: Difficulty) -> Self
Converts to this type from the input type.
source§impl From<Difficulty> for u8
impl From<Difficulty> for u8
source§fn from(_: Difficulty) -> Self
fn from(_: Difficulty) -> Self
Converts to this type from the input type.
source§impl Hash for Difficulty
impl Hash for Difficulty
source§impl Operation for Difficulty
impl Operation for Difficulty
§type ImmediateRef = Void
type ImmediateRef = Void
The return root type of
Operation::immediate_mut
and
Operation::immediate
.§type Code = Difficulty
type Code = Difficulty
The return type of
Operation::code
.source§fn immediate(&self) -> Option<&Self::ImmediateRef>
fn immediate(&self) -> Option<&Self::ImmediateRef>
Get a shared reference to the immediate argument of this operation,
if one exists.
source§fn immediate_mut(&mut self) -> Option<&mut Self::ImmediateRef>
fn immediate_mut(&mut self) -> Option<&mut Self::ImmediateRef>
Get a mutable reference to the immediate argument of this operation,
if one exists.
source§fn into_immediate(self) -> Option<Self::Immediate>
fn into_immediate(self) -> Option<Self::Immediate>
Consume this operation and return its immediate argument, if one
exists.
source§fn is_jump(&self) -> bool
fn is_jump(&self) -> bool
Returns true if the current instruction changes the program counter (other
than incrementing it.)
source§fn is_jump_target(&self) -> bool
fn is_jump_target(&self) -> bool
Returns true if the current instruction is a valid destination for jumps.
source§impl Ord for Difficulty
impl Ord for Difficulty
source§fn cmp(&self, other: &Difficulty) -> Ordering
fn cmp(&self, other: &Difficulty) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<Difficulty> for Difficulty
impl PartialEq<Difficulty> for Difficulty
source§fn eq(&self, other: &Difficulty) -> bool
fn eq(&self, other: &Difficulty) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<Difficulty> for Difficulty
impl PartialOrd<Difficulty> for Difficulty
source§fn partial_cmp(&self, other: &Difficulty) -> Option<Ordering>
fn partial_cmp(&self, other: &Difficulty) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for Difficulty
impl Eq for Difficulty
impl StructuralEq for Difficulty
impl StructuralPartialEq for Difficulty
Auto Trait Implementations§
impl RefUnwindSafe for Difficulty
impl Send for Difficulty
impl Sync for Difficulty
impl Unpin for Difficulty
impl UnwindSafe for Difficulty
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