Struct Comment

struct Comment { ... }

A comment from a regular expression with an associated span.

A regular expression can only contain comments when the x flag is enabled.

Fields

span: Span

The span of this comment, including the beginning # and ending \n.

comment: String

The comment text, starting with the first character following the # and ending with the last character preceding the \n.

Implementations

impl Clone for Comment

fn clone(self: &Self) -> Comment

impl Debug for Comment

fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result

impl Eq for Comment

impl Freeze for Comment

impl PartialEq for Comment

fn eq(self: &Self, other: &Comment) -> bool

impl RefUnwindSafe for Comment

impl Send for Comment

impl StructuralPartialEq for Comment

impl Sync for Comment

impl Unpin for Comment

impl UnsafeUnpin for Comment

impl UnwindSafe for Comment

impl<T> Any for Comment

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for Comment

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for Comment

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> CloneToUninit for Comment

unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)

impl<T> From for Comment

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> ToOwned for Comment

fn to_owned(self: &Self) -> T
fn clone_into(self: &Self, target: &mut T)

impl<T, U> Into for Comment

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for Comment

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for Comment

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>