pub struct PointerRefused {
pub element: String,
pub region: String,
}Expand description
Error representing a term pointer (TERM_POINTER)
that does not refer to the term of a term definition (id
flm.defterm.pointer-refused).
A term definition opens with a lead-in, such as Markov chain: . The
lead-in is written from the lead-in template of the feature
(DeftermConfig), in which #{term} stands for
the term being defined. At each term definition, #{term} is replaced by
a term pointer: a synthesized node that refers to the term argument of the
defterm environment. The lowering rule of the term pointer lowers the
term argument at the place of the pointer. A term pointer must refer to
the term argument of a defterm environment. This requirement ensures
that no content is written twice: any other content is already written
where its node is placed.
A document cannot cause this error: it is caused by the faulty code that
created the term pointer. Reported by the lowering rule of the term pointer
(PointerRule) when it is invoked. The term pointer
expands to nothing. The rest of the lead-in and the term definition are
written as usual.
Fields§
§element: StringThe name of the element of the node that the term pointer refers to.
region: StringThe node region that the term pointer refers to: an argument or a
content slot of the node
(NodeRegion), as text, e.g.
argument 0.
Implementations§
Trait Implementations§
Source§impl Clone for PointerRefused
impl Clone for PointerRefused
Source§impl Debug for PointerRefused
impl Debug for PointerRefused
Source§impl DiagnosticInfo for PointerRefused
impl DiagnosticInfo for PointerRefused
Source§const IDENTIFIER: &'static str = "flm.defterm.pointer-refused"
const IDENTIFIER: &'static str = "flm.defterm.pointer-refused"
<crate-or-lang>.<area>.<condition>. Read moreSource§fn serializable_data(&self) -> DiagnosticValue
fn serializable_data(&self) -> DiagnosticValue
Source§fn identifier(&self) -> &str
fn identifier(&self) -> &str
Source§impl Display for PointerRefused
impl Display for PointerRefused
impl Eq for PointerRefused
Source§impl PartialEq for PointerRefused
impl PartialEq for PointerRefused
impl StructuralPartialEq for PointerRefused
Auto Trait Implementations§
impl Forget for PointerRefused
impl Freeze for PointerRefused
impl Move for PointerRefused
impl RefUnwindSafe for PointerRefused
impl Send for PointerRefused
impl Sync for PointerRefused
impl Unpin for PointerRefused
impl UnsafeUnpin for PointerRefused
impl UnwindSafe for PointerRefused
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<T> DiagnosticData for Twhere
T: DiagnosticInfo,
impl<T> DiagnosticData for Twhere
T: DiagnosticInfo,
Source§fn identifier(&self) -> &str
fn identifier(&self) -> &str
DiagnosticInfo::identifier — for every
ordinary condition, the IDENTIFIER const).Source§fn serializable_data(&self) -> DiagnosticValue
fn serializable_data(&self) -> DiagnosticValue
DiagnosticInfo::serializable_data).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