pub struct SuppressionRange {
pub disable_comment: CommentData,
pub enable_comment: Option<CommentData>,
pub source: SuppressionSource,
}Expand description
Captures the start and end range of a pair of eslint-disable … eslint-enable comments. In the case of a CommentLine or a relevant Flow suppression, both the disable and enable point to the same comment.
The enable comment can be missing in the case where only a disable block is present, ie the rest of the file has potential React violations.
Fields§
§disable_comment: CommentData§enable_comment: Option<CommentData>§source: SuppressionSourceTrait Implementations§
Source§impl Clone for SuppressionRange
impl Clone for SuppressionRange
Source§fn clone(&self) -> SuppressionRange
fn clone(&self) -> SuppressionRange
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 SuppressionRange
impl RefUnwindSafe for SuppressionRange
impl Send for SuppressionRange
impl Sync for SuppressionRange
impl Unpin for SuppressionRange
impl UnsafeUnpin for SuppressionRange
impl UnwindSafe for SuppressionRange
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