pub struct MutableRange {
pub id: MutableRangeId,
pub start: EvaluationOrder,
pub end: EvaluationOrder,
}Fields§
§id: MutableRangeIdUnique identity for this logical range. Cloning preserves the ID
(same logical range); use Environment::new_mutable_range() to create
a range with a fresh ID.
start: EvaluationOrder§end: EvaluationOrderImplementations§
Source§impl MutableRange
impl MutableRange
Sourcepub fn contains(&self, eval_order: EvaluationOrder) -> bool
pub fn contains(&self, eval_order: EvaluationOrder) -> bool
Returns true if the given evaluation order falls within this mutable range.
Corresponds to TS inRange({id}, range) / isMutable(instr, place).
Sourcepub fn same_range(&self, other: &MutableRange) -> bool
pub fn same_range(&self, other: &MutableRange) -> bool
Returns true if this range has the same identity as other.
In the TS compiler, this corresponds to checking whether two mutableRange
references point to the same JS object (=== identity).
Trait Implementations§
Source§impl Clone for MutableRange
impl Clone for MutableRange
Source§fn clone(&self) -> MutableRange
fn clone(&self) -> MutableRange
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for MutableRange
impl RefUnwindSafe for MutableRange
impl Send for MutableRange
impl Sync for MutableRange
impl Unpin for MutableRange
impl UnsafeUnpin for MutableRange
impl UnwindSafe for MutableRange
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