[−][src]Struct nu_source::Span
Methods
impl Span
[src]
pub fn unknown() -> Span
[src]
pub fn new(start: usize, end: usize) -> Span
[src]
pub fn for_char(pos: usize) -> Span
[src]
pub fn until(&self, other: impl Into<Span>) -> Span
[src]
pub fn until_option(&self, other: Option<impl Into<Span>>) -> Span
[src]
pub fn string<'a>(&self, source: &'a str) -> String
[src]
pub fn spanned_slice<'a>(&self, source: &'a str) -> Spanned<&'a str>
[src]
pub fn spanned_string<'a>(&self, source: &'a str) -> Spanned<String>
[src]
pub fn start(&self) -> usize
[src]
pub fn end(&self) -> usize
[src]
pub fn is_unknown(&self) -> bool
[src]
pub fn slice<'a>(&self, source: &'a str) -> &'a str
[src]
Trait Implementations
impl HasSpan for Span
[src]
impl PrettyDebugWithSource for Span
[src]
fn pretty_debug(&self, source: &str) -> DebugDocBuilder
[src]
fn debug(&self, source: impl Into<Text>) -> String where
Self: Clone,
[src]
Self: Clone,
fn debuggable(self, source: impl Into<Text>) -> DebuggableWithSource<Self>
[src]
impl<'_, T> From<LocatedSpanEx<&'_ str, T>> for Span
[src]
fn from(input: LocatedSpanEx<&str, T>) -> Span
[src]
impl<T> From<(LocatedSpanEx<T, u64>, LocatedSpanEx<T, u64>)> for Span
[src]
fn from(input: (LocatedSpanEx<T, u64>, LocatedSpanEx<T, u64>)) -> Span
[src]
impl From<(usize, usize)> for Span
[src]
impl<'_> From<&'_ Range<usize>> for Span
[src]
impl From<Span> for Tag
[src]
impl<'_> From<&'_ Span> for Tag
[src]
impl From<Tag> for Span
[src]
impl<'_> From<&'_ Tag> for Span
[src]
impl<'_> From<&'_ Span> for Span
[src]
impl From<Option<Span>> for Span
[src]
impl Clone for Span
[src]
impl Copy for Span
[src]
impl Eq for Span
[src]
impl Ord for Span
[src]
fn cmp(&self, other: &Span) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
1.21.0[src]
fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<Span> for Span
[src]
impl PartialOrd<Span> for Span
[src]
fn partial_cmp(&self, other: &Span) -> Option<Ordering>
[src]
fn lt(&self, other: &Span) -> bool
[src]
fn le(&self, other: &Span) -> bool
[src]
fn gt(&self, other: &Span) -> bool
[src]
fn ge(&self, other: &Span) -> bool
[src]
impl Debug for Span
[src]
impl Hash for Span
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl StructuralPartialEq for Span
[src]
impl StructuralEq for Span
[src]
impl Serialize for Span
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<'de> Deserialize<'de> for Span
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl ReportingSpan for Span
[src]
Auto Trait Implementations
impl Send for Span
impl Sync for Span
impl Unpin for Span
impl UnwindSafe for Span
impl RefUnwindSafe for Span
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,