pub struct MalformedLabel {
pub text: String,
pub span: FlmSpan,
pub position: usize,
}Expand description
A text written as a label for a reference point that is not of the form
type:label, such as \label{intro}, with no colon.
Such a text defines no label: no reference resolves to it, and a point
whose labels are all of this kind is as unlabeled as one with no \label
at all. The construct that read the text records it on the point it
declares (RefPoint::malformed), and the refs feature
(crate::stdlib::features::refs) reports it once, as
flm.refs.bad-label, at the span of the field it was written in.
Fields§
§text: StringThe text as written, trimmed.
span: FlmSpanThe span of the field it was written in.
position: usizeThe position of this text among the point’s labels, counted from zero
over the labels (RefPoint::labels, the computed ones first) and
these texts together, in the order the document wrote them.
The labels and these texts are kept apart because almost every reader wants the labels alone. This position lets a reader that needs the written order restore it, as the recomposed LaTeX output does when it gives each label a key of its own.
Trait Implementations§
Source§impl Clone for MalformedLabel
impl Clone for MalformedLabel
Source§impl Debug for MalformedLabel
impl Debug for MalformedLabel
impl Eq for MalformedLabel
Source§impl PartialEq for MalformedLabel
impl PartialEq for MalformedLabel
impl StructuralPartialEq for MalformedLabel
Auto Trait Implementations§
impl Forget for MalformedLabel
impl Freeze for MalformedLabel
impl Move for MalformedLabel
impl RefUnwindSafe for MalformedLabel
impl Send for MalformedLabel
impl Sync for MalformedLabel
impl Unpin for MalformedLabel
impl UnsafeUnpin for MalformedLabelwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
*const ArcInner<Source<FlmOrigin>> is !null: UnsafeUnpin,
PhantomData<ArcInner<Source<FlmOrigin>>>: UnsafeUnpin,
impl UnwindSafe for MalformedLabel
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CheckedAs for T
impl<T> CheckedAs for T
Source§fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
Source§impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
Source§fn checked_cast_from(src: Src) -> Option<Dst>
fn checked_cast_from(src: Src) -> Option<Dst>
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more