pub enum UnquoteForm {
Unquote,
Splice,
}Expand description
Closed-set identifier for the syntactic marker of a macro-template
unquote (,) or unquote-splice (,@). Carried as a typed slot on
LispError::UnboundTemplateVar and LispError::NonSymbolUnquoteTarget
so authoring tools (REPL, LSP, tatara-check) bind to variant identity
via UnquoteForm::Splice rather than substring-matching the rendered
prefix literal.
Mirror at the template-marker boundary of the prior-run MacroDefHead
(macro-definition-head closed set), CompilerSpecIoStage
(disk-persistence surface), and TemplateInvariantKind (bytecode-runtime
surface) closed-set lifts: those enums key their respective rejection
variants on a typed identity; this enum keys the two unquote-template
rejection variants (UnboundTemplateVar, NonSymbolUnquoteTarget) on a
typed marker identity. Adding a new unquote variant (e.g., a hypothetical
,~ form) requires extending this enum, which rustc-enforces matching at
every projection site (marker()) — the closed set becomes a TYPE rather
than two &'static str-keyed slots that could drift independently.
marker(self) -> &'static str projects the typed UnquoteForm back to
the canonical literal for LispError::Display rendering. The &'static str lifetime is load-bearing: it lets both variants project through this
method into their compile error in {prefix}…: prefix without an
allocation, parallel to how MacroDefHead::keyword() and
CompilerSpecIoStage::operation() / label() feed their respective
LispError::* Display impls.
Theory anchor: THEORY.md §V.1 — knowable platform; the closed set of
unquote markers becomes a TYPE rather than a runtime
string-comparison-and-format dance. A typo like prefix: ",," is
structurally unrepresentable rather than re-asserted at the helper
boundary. THEORY.md §VI.1 — generation over composition; the typed enum
lands the structural-completeness floor for the template-marker surface,
parallel to how MacroDefHead lands it for the macro-definition-head
surface and CompilerSpecIoStage for the disk-persistence surface.
THEORY.md §II.1 invariant 1 (typed entry): a non-symbol unquote target /
an unbound template var is exactly the failure mode the typed-entry gate
exists to reject, and the marker identity is part of the proof.
Variants§
Unquote
,x — single-value substitution. The , marker; the inner symbol
is substituted with its bound value at template expansion.
Splice
,@x — list-splice substitution. The ,@ marker; the inner symbol
must be bound to a list, whose elements are flattened into the
containing list at template expansion.
Implementations§
Source§impl UnquoteForm
impl UnquoteForm
Sourcepub const ALL: [Self; 2]
pub const ALL: [Self; 2]
The closed set of two template-marker syntactic forms — single
source of truth that drives the Self::marker / [fmt::Display]
projection AND the [FromStr] decode sweep keyed on
Self::marker. Adding a hypothetical third variant (e.g. a
,~ reverse-unquote, a ,? conditional-unquote) lands at one
Self::ALL entry + one Self::marker arm — exhaustively
checked by the compiler (the [Self; 2] array literal forces
the arity) AND by the per-variant truth-table tests below.
Sibling closed-set lift to every other typed-shape enum the
substrate carries: this crate’s own SexpShape::ALL (the
twelve reachable outer shapes — superset on the structural axis
of the Sexp algebra), crate::ast::AtomKind::ALL (the six
atomic-payload kinds — peer axis on the same algebra),
crate::ast::QuoteForm (the four homoiconic prefix-wrappers
— superset of THIS enum’s two template markers via the 2-of-4
projection crate::ast::QuoteForm::as_unquote_form), and the
cross-crate tatara-process family (ConditionKind::ALL,
ProcessPhase::ALL, ProcessSignal::ALL, ChannelKind::ALL,
IntentKind::ALL, LifetimeKind::ALL, RequestorKind::ALL,
ReceiptKind::ALL, …) every one of which paired its typed
projection with ALL before this lift.
Future consumers that compose against ALL: LSP / REPL
completion for the operator-facing rendered template-marker
(every compile error in {prefix}…: substring in LispError’s
rendered diagnostics for a template-substitution rejection keys
on this set’s projection through Self::marker);
tatara-check coverage assertions over which template markers
reach a NonSymbolUnquoteTarget / UnboundTemplateVar arm at
all — the typed sweep replaces a per-callsite vocabulary of two
&'static str literals; any future audit-trail metric jointly
labeled by Self::marker (e.g.
tatara_lisp_unbound_template_var_total{prefix=","}) — the
metric label set IS Self::ALL mapped through
Self::marker; any future structural rewriter (typed
analogue of MLIR’s op.walk<UnquoteFormOp>()) that wants to
sweep over every template marker in a typed sequence.
Sourcepub const UNQUOTE_MARKER: &'static str = crate::ast::QuoteForm::UNQUOTE_PREFIX
pub const UNQUOTE_MARKER: &'static str = crate::ast::QuoteForm::UNQUOTE_PREFIX
Canonical &'static str template-marker bytes for the
Self::Unquote substitution — aliases
crate::ast::QuoteForm::UNQUOTE_PREFIX on the UnquoteForm ⊂
QuoteForm 2-of-4 subset carving so the marker-level per-role
bytes bind at ONE pub const on the parent superset’s Unquote
arm rather than at TWO sites (the per-role pub const AND a
parallel inline literal). Per-role peer of Self::Unquote on
the closed-set template-substitution algebra; consumers reach
for UnquoteForm::UNQUOTE_MARKER when the caller has a variant
in hand at compile time and wants the canonical diagnostic
bytes without runtime dispatch through Self::marker.
Sibling posture to crate::ast::AtomKind::SYMBOL_LABEL et al
(commit fc126b8) — both pin the invariant that a typed-subset
enum’s per-role bytes are structurally derived from the parent
superset’s per-role pub const via a pub const = Parent::CONST
alias rather than through parallel literal-discipline sites.
Sourcepub const SPLICE_MARKER: &'static str = crate::ast::QuoteForm::UNQUOTE_SPLICE_PREFIX
pub const SPLICE_MARKER: &'static str = crate::ast::QuoteForm::UNQUOTE_SPLICE_PREFIX
Canonical &'static str template-marker bytes for the
Self::Splice list-substitution — aliases
crate::ast::QuoteForm::UNQUOTE_SPLICE_PREFIX on the
UnquoteForm ⊂ QuoteForm 2-of-4 subset carving. Per-role peer of
Self::Splice; the ,@ two-byte prefix is the ONLY multi-char
bytes payload on the UnquoteForm algebra — every other marker
is a single-byte comma rendered as &'static str.
Sourcepub const MARKERS: [&'static str; 2]
pub const MARKERS: [&'static str; 2]
Closed-set forced-arity ALL array over the canonical template-
marker &'static str bytes, in declaration order matching
Self::ALL element-wise (pinned by
unquote_form_markers_align_with_all_by_index). Sibling posture
to crate::ast::QuoteForm::PREFIXES ([&'static str; 4] —
the superset carving this UnquoteForm subset embeds into),
crate::ast::AtomKind::LABELS ([&'static str; 6] — sibling
subset-through-parent alias on the AtomKind ⊂ SexpShape
carving), SexpShape::LABELS ([&'static str; 12]),
ExpectedKwargShape::LABELS ([&'static str; 7]),
KwargPathKind::LABELS ([&'static str; 3]),
MacroDefHead::KEYWORDS ([&'static str; 3]),
crate::ast::Atom::BOOL_LITERALS ([&'static str; 2]), and
crate::macro_expand::MacroParams::LAMBDA_LIST_KEYWORDS
([&'static str; 2]) — every closed-set outer projection on
the substrate that carries an &'static str-per-variant marker
now pins its per-role canonical bytes at ONE pub const per
role PLUS an ALL array for family-wide consumers.
Pre-lift the two template-marker bytes had NO per-role primitive
on this closed-set subset algebra — a consumer with an
UnquoteForm variant in hand at compile time reaching for the
canonical marker bytes had to spell
UnquoteForm::Splice.marker() (runtime dispatch through the
composition Self::to_quote_form +
crate::ast::QuoteForm::prefix) OR reach across the algebra
boundary into crate::ast::QuoteForm::UNQUOTE_SPLICE_PREFIX
and re-derive the UnquoteForm ⊂ QuoteForm variant pairing at
the call site. Post-lift the TWO canonical bytes bind at ONE
pub const per role on the typed UnquoteForm algebra AND
at Self::MARKERS as a family-wide forced-arity array — a
future LSP / REPL completion bar keyed on
UnquoteForm::MARKERS, a tatara-check coverage sweep over
the template-marker arms of a NonSymbolUnquoteTarget /
UnboundTemplateVar corpus, or a Sekiban audit-trail metric
jointly labeled by the template marker
(tatara_lisp_unbound_template_var_total{prefix=","}) reads
through the typed constants on this subset algebra without
re-deriving the 2-of-4 carving inline.
Each entry is byte-for-byte identical to the corresponding
crate::ast::QuoteForm Unquote / UnquoteSplice arm — an
intentional cross-axis overlap pinned by
unquote_form_per_role_markers_alias_quote_form_per_role_prefixes_byte_for_byte
so a future marker rename on EITHER side (a
crate::ast::QuoteForm "," → ",." drift, or an
UnquoteForm rename that skips the alias) fails-loudly at
the alias test rather than as a silent operator-facing
vocabulary fracture. Adding a hypothetical third template-
marker (e.g. a ,~ reverse-unquote, a ,? conditional-unquote)
extends Self::ALL AND Self::MARKERS AND adds ONE per-
role pub const alias in lockstep — rustc’s forced-arity check
on the two [_; N] arrays fails compilation if EITHER ALL
array grows without the other.
Theory anchor: THEORY.md §III — the typescape; the two
canonical template-marker bytes bind at ONE typed
[&'static str; 2] array on the closed-set UnquoteForm algebra
rather than at zero-primitive-on-this-subset-plus-two-inline-
lookups scattered across the substrate. THEORY.md §V.1 —
knowable platform; the family’s cardinality becomes a TYPE-
level constant on the substrate algebra rather than a per-
consumer runtime dispatch through the composition. THEORY.md
§VI.1 — generation over composition; the family-wide contract
sweeps (alignment with ALL, pairwise disjointness, membership
through Self::marker) emerge from the composition of TWO
substrate primitives (this pub const array + the two per-role
pub const *_MARKER aliases) rather than as per-variant inline
assertions duplicated at each call site.
Sourcepub const UNQUOTE_LEAD: char = crate::ast::QuoteForm::UNQUOTE_LEAD
pub const UNQUOTE_LEAD: char = crate::ast::QuoteForm::UNQUOTE_LEAD
Canonical reader-lead char byte for BOTH Self::Unquote AND
Self::Splice — aliases crate::ast::QuoteForm::UNQUOTE_LEAD
(which is ',') on the UnquoteForm ⊂ QuoteForm 2-of-4 subset
carving so the reader-lead-char per-role bytes bind at ONE
pub const on the parent superset’s Unquote arm rather than at
TWO sites (the per-role pub const AND a parallel inline ','
literal). Per-role peer of Self::Unquote on the closed-set
template-substitution algebra; consumers reach for
UnquoteForm::UNQUOTE_LEAD when the caller has a variant in
hand at compile time and wants the canonical reader-entry lead
char without runtime dispatch through
self.to_quote_form().lead_char().
The (2-of-2 collapse) shape-asymmetry is load-bearing: BOTH
UnquoteForm arms share the SAME lead char at
crate::ast::QuoteForm::lead_char’s Self::Unquote | Self::UnquoteSplice => Self::UNQUOTE_LEAD merged arm — the
reader’s outer tokenizer dispatch selects between quote-family
entry and every non-quote-family arm on lead char alone, with
the ,-vs-,@ disambiguation falling out of the reader’s
second-char peek (@ promotes to Splice) rather than at
crate::ast::QuoteForm::from_lead_char’s decode. This
UnquoteForm ⊂ QuoteForm subset’s LEAD alias is
SHAPE-ASYMMETRIC-COLLAPSE to [Self::UNQUOTE_LEAD] (a
single-entry ALL — see Self::LEADS) because both subset
arms project to the same superset lead byte, mirroring the
parent’s [QUOTE_LEAD, QUASIQUOTE_LEAD, UNQUOTE_LEAD] shape-
asymmetric collapse (3 distinct leads for 4 arms).
Sibling posture to Self::UNQUOTE_MARKER (commit 3640f76 —
aliases the reader-punctuation prefix vocabulary ","),
Self::UNQUOTE_LABEL (commit da68af5 — aliases the
substrate diagnostic-label vocabulary "unquote"),
Self::UNQUOTE_IAC_FORGE_TAG (commit 6acab84 — aliases the
iac-forge canonical-form vocabulary "unquote"), and
Self::UNQUOTE_HASH_DISCRIMINATOR (commit eca4730 —
aliases the outer-Sexp cache-key u8 byte 5u8) — this
FIFTH per-role pub const axis closes the (reader-lead char,
reader-prefix bytes, diagnostic label, iac-forge canonical-form
tag, outer-Sexp cache-key byte) QUINTUPLE on the UnquoteForm
subset algebra in lockstep with the same quintuple on the
parent crate::ast::QuoteForm superset.
Sourcepub const LEADS: [char; 1]
pub const LEADS: [char; 1]
Closed-set forced-arity ALL array over the canonical
reader-lead char bytes on the UnquoteForm ⊂ QuoteForm 2-of-4
subset carving — SHAPE-ASYMMETRIC-COLLAPSE [char; 1] on this
subset carving (both arms share the same ',' lead byte), peer
to crate::ast::QuoteForm::LEADS ([char; 3] on the 4-arm
superset carving, itself shape-asymmetric-collapse from 4 arms
to 3 distinct leads because crate::ast::QuoteForm::Unquote
and crate::ast::QuoteForm::UnquoteSplice share the same
lead byte).
Peer axis to Self::MARKERS on the SAME reader-vocabulary
production surface: Self::MARKERS holds the arm-per-arm
prefix bytes (",", ",@" — cardinality matches Self::ALL
at [_; 2]), and Self::LEADS holds the DISTINCT lead-byte
sub-vocabulary the reader’s outer tokenizer dispatch selects on
("," alone — cardinality collapses from 2 arms to 1 distinct
lead byte). The shape-asymmetric arities [_; 2] for MARKERS
vs [_; 1] for LEADS ARE the shared-lead-char structural
collapse invariant carried at the type-system level — a future
third UnquoteForm arm (e.g. a hypothetical ,~ reverse-unquote
binding a NEW lead char ~) would extend BOTH Self::MARKERS
to [_; 3] AND Self::LEADS to [_; 2] in lockstep, adding
ONE per-role LEAD pub const alias.
Sibling posture to crate::ast::QuoteForm::LEADS (the
superset carving’s own DISTINCT-lead-byte ALL array on the
SAME reader-lead-vocabulary axis), Self::MARKERS,
Self::LABELS, Self::IAC_FORGE_TAGS, and
Self::HASH_DISCRIMINATORS — every one a forced-arity ALL
array on the SAME UnquoteForm closed-set algebra spanning ONE
of the production byte-vocabularies the substrate carries per
role.
Pre-lift the sole distinct lead byte had NO per-role primitive
on this closed-set subset algebra — a consumer wanting the
UnquoteForm-only reader-lead-byte set had to spell the two-
step composition UnquoteForm::ALL.iter().map(|uf| uf.to_quote_form().lead_char()).collect() (with a manual dedup
downstream to project the 2-arm output onto its 1 distinct
byte) OR reach across into
crate::ast::QuoteForm::UNQUOTE_LEAD and re-derive the
UnquoteForm ⊂ QuoteForm variant-share pairing at the call site.
Post-lift the sole canonical byte binds at ONE pub const on
the typed UnquoteForm algebra AND at Self::LEADS as a
family-wide [char; 1] forced-arity array — a future
substrate-facing reader-classifier keyed on the substitution-
subset’s lead-vocabulary specifically (a future LSP completion
bar filtering to template-substitution-only entries, a
syntax-highlighter’s per-char classifier for the reader-entry
template-marker subset, a tatara-check predicate
(check-substitution-subset-lead-partition …) that verifies
the subset’s sole lead byte sits inside the parent
crate::ast::QuoteForm::LEADS set) reads through the typed
constants without re-deriving the 2-of-4 → 1-of-3 collapse
inline.
Theory anchor: THEORY.md §III — the typescape; the sole
canonical distinct-lead byte on the substitution-subset
carving binds at ONE typed [char; 1] array on the closed-set
UnquoteForm algebra rather than as a zero-primitive-on-this-
subset-plus-inline-lookup at each callsite. Closes the FIFTH
per-role pub const axis on the UnquoteForm subset carving in
lockstep with the same quintuple on crate::ast::QuoteForm.
THEORY.md §V.1 — knowable platform; the SHAPE-ASYMMETRIC-
COLLAPSE distinct-lead-byte sub-vocabulary becomes load-bearing
typed data on the substrate’s substitution-subset closed set —
the type-system carries the “both subset arms share ONE lead”
invariant at the [char; 1] arity rather than as a comment on
a lookup site. THEORY.md §VI.1 — generation over composition;
the family-wide contract sweeps (alignment with the parent
crate::ast::QuoteForm::LEADS’s subset image, cardinality
containment Self::LEADS.len() <= Self::ALL.len() — the
collapse witness) emerge from ONE substrate primitive plus the
per-role LEAD alias rather than from per-consumer runtime
dispatch through the two-step composition.
Sourcepub const UNQUOTE_IAC_FORGE_TAG: &'static str = crate::ast::QuoteForm::UNQUOTE_IAC_FORGE_TAG
pub const UNQUOTE_IAC_FORGE_TAG: &'static str = crate::ast::QuoteForm::UNQUOTE_IAC_FORGE_TAG
Canonical &'static str iac-forge canonical-form tag bytes for
the Self::Unquote substitution — aliases
crate::ast::QuoteForm::UNQUOTE_IAC_FORGE_TAG on the
UnquoteForm ⊂ QuoteForm 2-of-4 subset carving so the
iac-forge-tag-level per-role bytes bind at ONE pub const on
the parent superset’s Unquote arm rather than at TWO sites (the
per-role pub const AND a parallel inline literal). Per-role
peer of Self::Unquote on the closed-set template-
substitution algebra; consumers reach for
UnquoteForm::UNQUOTE_IAC_FORGE_TAG when the caller has a
variant in hand at compile time and wants the canonical iac-
forge interop-tag bytes without runtime dispatch through
Self::iac_forge_tag.
Sibling posture to Self::UNQUOTE_MARKER (commit 3640f76) —
both pin the invariant that a typed-subset enum’s per-role
bytes are structurally derived from the parent superset’s
per-role pub const via a pub const = Parent::CONST alias
rather than through parallel literal-discipline sites. Where
Self::UNQUOTE_MARKER aliases the reader-punctuation
vocabulary (",") shared with the Lisp source-code surface,
this constant aliases the iac-forge canonical-form vocabulary
("unquote") shared with the cross-crate attestation surface
— the two peer axes span the two production byte-vocabularies
the parent crate::ast::QuoteForm closed set carries, and
both now bind through the same aliased typed source of truth on
this UnquoteForm subset.
Sourcepub const SPLICE_IAC_FORGE_TAG: &'static str = crate::ast::QuoteForm::UNQUOTE_SPLICE_IAC_FORGE_TAG
pub const SPLICE_IAC_FORGE_TAG: &'static str = crate::ast::QuoteForm::UNQUOTE_SPLICE_IAC_FORGE_TAG
Canonical &'static str iac-forge canonical-form tag bytes for
the Self::Splice list-substitution — aliases
crate::ast::QuoteForm::UNQUOTE_SPLICE_IAC_FORGE_TAG on the
UnquoteForm ⊂ QuoteForm 2-of-4 subset carving. Per-role peer of
Self::Splice; the "unquote-splicing" bytes are the ONLY
hyphenated multi-syllable canonical-form tag on the UnquoteForm
algebra — the other iac-forge tag is a single word.
INTENTIONALLY diverges from crate::error::SexpShape::label’s
splice arm (which renders "unquote-splice" for the diagnostic
surface) — the iac-forge canonical-form REQUIRES the
unquote-splicing spelling, while the substrate’s operator-
facing diagnostic surface renders the shorter idiom. The typed
per-role pub const documents the divergence structurally: a
future “consolidation” PR that homogenizes the two axes would
have to touch this constant explicitly, surfacing the boundary-
distinct invariant at code-review time rather than silently.
Sourcepub const IAC_FORGE_TAGS: [&'static str; 2]
pub const IAC_FORGE_TAGS: [&'static str; 2]
Closed-set forced-arity ALL array over the canonical iac-forge
canonical-form tag &'static str bytes, in declaration order
matching Self::ALL element-wise (pinned by
unquote_form_iac_forge_tags_align_with_all_by_index). Sibling
posture to Self::MARKERS ([&'static str; 2] on the reader-
punctuation axis of the SAME UnquoteForm closed set — commit
3640f76) and to crate::ast::QuoteForm::IAC_FORGE_TAGS
([&'static str; 4] — the superset carving this UnquoteForm
subset embeds into on the SAME iac-forge canonical-form axis).
The (canonical iac-forge tag) axis + the (canonical reader
marker) axis together span the two production byte-vocabularies
the UnquoteForm closed set carries — Self::MARKERS holds
the Lisp source-code prefixes (",", ",@") the reader
tokenizes on, Self::IAC_FORGE_TAGS holds the cross-crate
canonical-form tag strings ("unquote", "unquote-splicing")
the iac-forge interop layer round-trips through.
Pre-lift the two iac-forge tag bytes had NO per-role primitive
on this closed-set subset algebra — a consumer with an
UnquoteForm variant in hand at compile time reaching for
the canonical tag bytes had to spell
UnquoteForm::Splice.iac_forge_tag() (runtime dispatch through
the composition Self::to_quote_form +
crate::ast::QuoteForm::iac_forge_tag) OR reach across the
algebra boundary into
crate::ast::QuoteForm::UNQUOTE_SPLICE_IAC_FORGE_TAG and
re-derive the UnquoteForm ⊂ QuoteForm variant pairing at the
call site. Post-lift the TWO canonical bytes bind at ONE
pub const per role on the typed UnquoteForm algebra AND
at Self::IAC_FORGE_TAGS as a family-wide forced-arity array
— a future LSP / REPL completion bar keyed on
UnquoteForm::IAC_FORGE_TAGS, a tatara-check coverage sweep
over the template-marker arms of an attestation-payload corpus,
or a Sekiban audit-trail metric jointly labeled by the iac-
forge tag (tatara_lisp_iac_forge_tag_total{tag="unquote"})
reads through the typed constants on this subset algebra
without re-deriving the 2-of-4 carving inline.
Each entry is byte-for-byte identical to the corresponding
crate::ast::QuoteForm Unquote / UnquoteSplice arm — an
intentional cross-axis overlap pinned by
unquote_form_per_role_iac_forge_tags_alias_quote_form_per_role_iac_forge_tags_byte_for_byte
so a future canonical-form tag rename on EITHER side (a
crate::ast::QuoteForm "unquote" → "unquote-value" drift,
or an UnquoteForm rename that skips the alias) fails-loudly
at the alias test rather than as a silent cross-crate
canonical-form vocabulary fracture that mis-hashes BLAKE3
attestation keys. Adding a hypothetical third template-marker
(e.g. a ,~ reverse-unquote with its own canonical "reverse- unquote" tag, a ,? conditional-unquote with its own tag)
extends Self::ALL AND Self::IAC_FORGE_TAGS AND adds ONE
per-role pub const alias in lockstep — rustc’s forced-arity
check on the two [_; N] arrays fails compilation if EITHER
ALL array grows without the other.
Theory anchor: THEORY.md §III — the typescape; the two
canonical iac-forge tag bytes bind at ONE typed
[&'static str; 2] array on the closed-set UnquoteForm algebra
rather than at zero-primitive-on-this-subset-plus-two-inline-
lookups scattered across the substrate. THEORY.md §V.1 —
knowable platform; the family’s cardinality becomes a TYPE-
level constant on the substrate algebra rather than a per-
consumer runtime dispatch through the composition. THEORY.md
§V.3 — three-pillar attestation; the canonical iac-forge tag
bytes are the surface the substrate’s cross-crate intent_hash
pillar composes over for every substitution-subset arm of a
homoiconic template AST — binding the two bytes on the typed
algebra makes attestation-key drift a compile error rather than
a silent BLAKE3 mis-hash. THEORY.md §VI.1 — generation over
composition; the family-wide contract sweeps (alignment with
ALL, pairwise disjointness, membership through
Self::iac_forge_tag) emerge from the composition of TWO
substrate primitives (this pub const array + the two per-role
pub const *_IAC_FORGE_TAG aliases) rather than as per-variant
inline assertions duplicated at each call site.
Sourcepub const UNQUOTE_LABEL: &'static str = crate::ast::QuoteForm::UNQUOTE_LABEL
pub const UNQUOTE_LABEL: &'static str = crate::ast::QuoteForm::UNQUOTE_LABEL
Canonical &'static str diagnostic label bytes for the
Self::Unquote substitution — aliases
crate::ast::QuoteForm::UNQUOTE_LABEL on the UnquoteForm ⊂
QuoteForm 2-of-4 subset carving so the label-level per-role
bytes bind at ONE pub const on the parent superset’s Unquote
arm (which itself aliases SexpShape::UNQUOTE_LABEL on the
QuoteForm ⊂ SexpShape 4-of-12 subset carving) rather than at
multiple sites (the per-role pub const PLUS a parallel inline
literal). Per-role peer of Self::Unquote on the closed-set
template-substitution algebra; consumers reach for
UnquoteForm::UNQUOTE_LABEL when the caller has a variant in
hand at compile time and wants the canonical diagnostic bytes
without runtime dispatch through Self::label.
Sibling posture to Self::UNQUOTE_MARKER (commit 3640f76 —
aliases the reader-punctuation vocabulary ",") and to
Self::UNQUOTE_IAC_FORGE_TAG (commit 6acab84 — aliases the
iac-forge canonical-form vocabulary "unquote") — this THIRD
per-role pub const axis closes the (reader punctuation,
diagnostic label, iac-forge canonical-form) triple on the
UnquoteForm subset algebra in lockstep with the same triple
on the parent crate::ast::QuoteForm superset. At the
Unquote arm the diagnostic label AND the iac-forge tag AND the
substrate-facing SexpShape::UNQUOTE_LABEL all agree
byte-for-byte on "unquote"; the divergence axis lives at
Self::SPLICE_LABEL ("unquote-splice") vs
Self::SPLICE_IAC_FORGE_TAG ("unquote-splicing").
Sourcepub const SPLICE_LABEL: &'static str = crate::ast::QuoteForm::UNQUOTE_SPLICE_LABEL
pub const SPLICE_LABEL: &'static str = crate::ast::QuoteForm::UNQUOTE_SPLICE_LABEL
Canonical &'static str diagnostic label bytes for the
Self::Splice list-substitution — aliases
crate::ast::QuoteForm::UNQUOTE_SPLICE_LABEL on the
UnquoteForm ⊂ QuoteForm 2-of-4 subset carving. Per-role peer of
Self::Splice. The "unquote-splice" short label matches
SexpShape::UNQUOTE_SPLICE_LABEL byte-for-byte through the
alias chain and diverges INTENTIONALLY from
Self::SPLICE_IAC_FORGE_TAG ("unquote-splicing") — the two
projections key the SAME closed set on TWO distinct boundaries
(substrate diagnostic surface vs cross-crate Common-Lisp
canonical form). See Self::UNQUOTE_LABEL for the alias-
chain shape both siblings share.
Sourcepub const LABELS: [&'static str; 2]
pub const LABELS: [&'static str; 2]
Closed-set forced-arity ALL array over the canonical diagnostic
label &'static str bytes, in declaration order matching
Self::ALL element-wise (pinned by
unquote_form_labels_align_with_all_by_index). Sibling posture
to Self::MARKERS ([&'static str; 2] — reader-punctuation
axis) and Self::IAC_FORGE_TAGS ([&'static str; 2] — iac-
forge canonical-form axis) on the SAME UnquoteForm closed set,
and to crate::ast::QuoteForm::LABELS ([&'static str; 4] —
the superset carving this UnquoteForm subset embeds into on the
SAME diagnostic-label axis). The (diagnostic label) axis + the
(reader punctuation) axis + the (iac-forge canonical-form)
axis together span the THREE production byte-vocabularies the
UnquoteForm closed set carries — Self::MARKERS holds
the Lisp source-code prefixes (",", ",@"), Self::LABELS
holds the substrate diagnostic labels ("unquote",
"unquote-splice"), Self::IAC_FORGE_TAGS holds the cross-
crate canonical-form tag strings ("unquote", "unquote- splicing").
Pre-lift the two diagnostic-label bytes had NO per-role
primitive on this closed-set subset algebra — a consumer with
an UnquoteForm variant in hand at compile time reaching for
the canonical diagnostic bytes had to spell the two-step
composition uf.to_quote_form().label() OR reach across the
algebra boundary into
crate::ast::QuoteForm::UNQUOTE_SPLICE_LABEL and re-derive
the UnquoteForm ⊂ QuoteForm variant pairing at the call site.
Post-lift the TWO canonical bytes bind at ONE pub const per
role on the typed UnquoteForm algebra AND at
Self::LABELS as a family-wide forced-arity array — a
future LSP / REPL completion bar keyed on
UnquoteForm::LABELS, a tatara-check coverage sweep over
the template-marker arms of a diagnostic corpus, or a Sekiban
audit-trail metric jointly labeled by the diagnostic label
(tatara_lisp_unbound_template_var_total{label="unquote"})
reads through the typed constants on this subset algebra
without re-deriving the 2-of-4 carving inline.
Each entry is byte-for-byte identical to the corresponding
crate::ast::QuoteForm Unquote / UnquoteSplice arm — an
intentional cross-axis overlap pinned by
unquote_form_per_role_labels_alias_quote_form_per_role_labels_byte_for_byte
so a future label rename on EITHER side (a
crate::ast::QuoteForm "unquote" → "substitute" drift,
or an UnquoteForm rename that skips the alias) fails-
loudly at the alias test rather than as a silent operator-
facing vocabulary fracture. Adding a hypothetical third
template-marker (e.g. a ,~ reverse-unquote) extends
Self::ALL AND Self::LABELS AND adds ONE per-role
pub const alias in lockstep — rustc’s forced-arity check on
the two [_; N] arrays fails compilation if EITHER array
grows without the other.
Theory anchor: THEORY.md §III — the typescape; the two
canonical diagnostic label bytes bind at ONE typed
[&'static str; 2] array on the closed-set UnquoteForm algebra
rather than at zero-primitive-on-this-subset-plus-two-inline-
lookups scattered across the substrate. Closes the THIRD
per-role pub const axis on the UnquoteForm subset carving in
lockstep with the same triple on crate::ast::QuoteForm.
THEORY.md §V.1 — knowable platform; the family’s cardinality
becomes a TYPE-level constant on the substrate algebra rather
than a per-consumer runtime dispatch through the composition.
THEORY.md §VI.1 — generation over composition; the family-wide
contract sweeps (alignment with ALL, pairwise disjointness,
membership through Self::label) emerge from the composition
of TWO substrate primitives (this pub const array + the two
per-role pub const *_LABEL aliases) rather than as per-
variant inline assertions duplicated at each call site.
THEORY.md §II.1 invariant 5 — composition preserves proofs;
the alias-chain composition law UnquoteForm::LABELS[i] == UnquoteForm::ALL[i].to_quote_form().label() binds the family-
wide array to the composition through Self::to_quote_form +
crate::ast::QuoteForm::label at rustc time.
Sourcepub const UNQUOTE_SHAPE: SexpShape = crate::ast::QuoteForm::UNQUOTE_SHAPE
pub const UNQUOTE_SHAPE: SexpShape = crate::ast::QuoteForm::UNQUOTE_SHAPE
Canonical SexpShape embed target for the Self::Unquote
template-substitution arm on the UnquoteForm ⊂ QuoteForm ⊂
SexpShape composed carving — aliases
crate::ast::QuoteForm::UNQUOTE_SHAPE on the parent’s 4-of-12
quote-family carving byte-for-byte (which in turn aliases
SexpShape::Unquote). Per-role peer of Self::Unquote on the
closed-set UnquoteForm ⊂ SexpShape 2-of-12 composed embed axis;
consumers with an UnquoteForm variant in hand at compile time
bind the canonical embed target through ONE typed pub const on
the subset algebra rather than through runtime dispatch via
Self::sexp_shape OR by reaching across the two-hop
Self::to_quote_form().sexp_shape() composition OR by re-deriving
the UnquoteForm ⊂ QuoteForm ⊂ SexpShape variant pairing inline.
Sibling posture to Self::UNQUOTE_MARKER on the reader-prefix
axis, Self::UNQUOTE_LEAD on the reader-lead axis,
Self::UNQUOTE_IAC_FORGE_TAG on the iac-forge canonical-form tag
axis, Self::UNQUOTE_LABEL on the diagnostic-label axis, and
Self::UNQUOTE_HASH_DISCRIMINATOR on the outer-Sexp cache-key
byte axis — every one of the pre-existing per-role sub-vocabulary
aliases on this subset algebra now has a peer per-role
SexpShape embed-target alias on the SAME closed-set
UnquoteForm ⊂ QuoteForm 2-of-4 subset carving.
Sourcepub const SPLICE_SHAPE: SexpShape = crate::ast::QuoteForm::UNQUOTE_SPLICE_SHAPE
pub const SPLICE_SHAPE: SexpShape = crate::ast::QuoteForm::UNQUOTE_SPLICE_SHAPE
Canonical SexpShape embed target for the Self::Splice
template-substitution arm on the UnquoteForm ⊂ QuoteForm ⊂
SexpShape composed carving — aliases
crate::ast::QuoteForm::UNQUOTE_SPLICE_SHAPE on the parent’s
4-of-12 quote-family carving byte-for-byte (which in turn aliases
SexpShape::UnquoteSplice). Per-role peer of Self::Splice on
the closed-set UnquoteForm ⊂ SexpShape 2-of-12 composed embed
axis. See Self::UNQUOTE_SHAPE for the alias-chain shape every
sibling shares.
Sourcepub const SHAPES: [SexpShape; 2]
pub const SHAPES: [SexpShape; 2]
Closed-set forced-arity ALL array over the canonical
SexpShape embed targets on the UnquoteForm ⊂ SexpShape
2-of-12 composed carving, in declaration order matching
Self::ALL element-wise (pinned by
unquote_form_shapes_align_with_all_by_index). Sibling posture
to Self::MARKERS ([&'static str; 2] — reader-prefix bytes),
Self::LEADS ([char; 1] — SHAPE-ASYMMETRIC-COLLAPSE distinct-
lead byte), Self::IAC_FORGE_TAGS ([&'static str; 2] — iac-
forge canonical-form tags), Self::LABELS ([&'static str; 2]
— diagnostic labels), Self::HASH_DISCRIMINATORS ([u8; 2] —
outer-Sexp cache-key bytes), and Self::PROMOTIONS
([(Self, char, Self); 1] — SHAPE-ASYMMETRIC-COLLAPSE promotion
triples) on the SAME closed-set UnquoteForm algebra; where those
six arrays lift per-role sub-vocabularies on the substitution
subset algebra, this array lifts the per-role SexpShape
embed-target sub-vocabulary at the same [_; 2] forced arity.
Aliased through crate::ast::QuoteForm::UNQUOTE_SHAPE +
crate::ast::QuoteForm::UNQUOTE_SPLICE_SHAPE via the per-role
Self::UNQUOTE_SHAPE + Self::SPLICE_SHAPE constants — the
UnquoteForm ⊂ QuoteForm 2-of-4 subset carving of the parent’s
4-of-12 quote-family SHAPES. Sibling posture to
crate::ast::QuoteForm::SHAPES ([SexpShape; 4]) —
the parent superset’s peer array on the QuoteForm ⊂ SexpShape
4-of-12 carving; together with the three closed-set carvings’
arrays (crate::ast::AtomKind::SHAPES 6-of-12,
crate::ast::QuoteForm::SHAPES 4-of-12,
StructuralKind::SHAPES 2-of-12) the four SHAPES arrays now
close the FULL twelve-arm outer-shape algebra uniformly PLUS the
UnquoteForm 2-of-4 subset carving of the quote-family sub-
algebra.
Pre-lift the two SexpShape embed targets had NO per-role
primitive on this subset algebra — a consumer with an
UnquoteForm variant in hand at compile time reaching for the
canonical embed target had to spell
UnquoteForm::Unquote.sexp_shape() (runtime dispatch through
Self::sexp_shape’s two-hop .to_quote_form().sexp_shape()
composition) OR reach across into
crate::ast::QuoteForm::UNQUOTE_SHAPE and re-derive the
UnquoteForm ⊂ QuoteForm 2-of-4 subset pairing at the call site.
Post-lift the TWO canonical embed targets bind at ONE pub const
per role on the typed UnquoteForm subset algebra AND at
Self::SHAPES as a family-wide forced-arity array — a future
LSP / REPL completion bar keyed on UnquoteForm::SHAPES for the
“which SexpShape does this UnquoteForm embed into?” outer-shape
column, a tatara-check coverage sweep zipping
UnquoteForm::ALL / LABELS / MARKERS / LEADS /
IAC_FORGE_TAGS / HASH_DISCRIMINATORS / PROMOTIONS /
SHAPES in lockstep for a family-wide (variant, label, marker,
lead, iac-forge tag, cache-key byte, promotion triple, embed-
target) octuple render, or a Sekiban audit-trail metric jointly
labeled by the embed target’s SexpShape identity reads through
the typed constants on this subset algebra without re-deriving
the 2-of-12 composed carving inline.
Round-trip identity with the inverse projection
SexpShape::as_unquote_form: for every index i,
Self::SHAPES[i].as_unquote_form() == Some(Self::ALL[i]) (pinned
by unquote_form_shapes_align_with_all_by_index_through_as_unquote_form)
— the embed / project section closes as a family-wide array-
indexed law on the composed 2-of-12 carving rather than as a
per-variant assertion sweep. Adding a hypothetical third
template-substitution marker (e.g. ,~ reverse-unquote for
destructuring-bind hygiene, ,? conditional-unquote) extends
Self::ALL AND Self::SHAPES AND
crate::ast::QuoteForm::ALL AND
crate::ast::QuoteForm::SHAPES AND SexpShape::ALL AND adds
ONE per-role pub const *_SHAPE in lockstep — rustc’s forced-
arity check on the two [_; N] arrays fails compilation if
EITHER ALL array grows without the other, AND the peer
SexpShape::as_unquote_form arm must grow in lockstep to
preserve the round-trip identity.
Theory anchor: THEORY.md §III — the typescape; the two canonical
SexpShape embed targets bind at ONE typed [SexpShape; 2]
array on the closed-set UnquoteForm subset algebra rather than at
zero-primitive-on-this-subset-plus-two-inline-lookups-through-
two-hop-composition scattered across the substrate. THEORY.md
§II.1 invariant 2 — free middle; the (embed, project) pair binds
at THREE typed sites now — the projection method
Self::sexp_shape, this family-wide array, AND the peer inverse
SexpShape::as_unquote_form — with rustc-enforced consistency
across all three via the array-indexed round-trip law. THEORY.md
§V.1 — knowable platform; the family’s cardinality becomes a
TYPE-level constant on the substrate algebra rather than a per-
consumer runtime dispatch through the two-hop composition.
THEORY.md §VI.1 — generation over composition; the family-wide
contract sweeps (alignment with ALL, round-trip through
as_unquote_form, membership through sexp_shape, pairwise
injectivity across the two embed targets, alias byte-equality
with QuoteForm’s per-role SHAPE constants) emerge from the
composition of TWO substrate primitives (this pub const array +
the two per-role pub const *_SHAPE aliases) rather than as
per-variant inline assertions duplicated at each call site.
Sourcepub fn marker(self) -> &'static str
pub fn marker(self) -> &'static str
Project the typed UnquoteForm to the canonical &'static str
literal — feeds the LispError::UnboundTemplateVar /
LispError::NonSymbolUnquoteTarget Display rendering via the
#[error(...)] annotation. The &'static str lifetime is
load-bearing: it lets the variants project through this method into
their compile error in {prefix}…: prefix without an allocation,
parallel to how MacroDefHead::keyword() and
CompilerSpecIoStage::operation() / label() feed their respective
LispError::* Display impls.
Composition law: self.marker() == self.to_quote_form().prefix()
for every self: UnquoteForm. Pre-lift the body inlined the two
literals ("," / ",@") as a parallel match-table; the same two
literals also lived at the matching Unquote/UnquoteSplice arms of
crate::ast::QuoteForm::prefix. Post-lift the body composes
Self::to_quote_form() (the typed 2-of-4 subset → superset
projection) with crate::ast::QuoteForm::prefix() (the canonical
4-of-4 prefix-string projection), so the two &'static str
literals live at ONE canonical site (QuoteForm::prefix’s
Unquote/UnquoteSplice arms in ast.rs) and every consumer of
UnquoteForm::marker (the ClosedSet-trait Display/FromStr
surface via #[closed_set(via = "marker")], the unbound-template
did you mean ,@args? hint suffix in this module’s
unbound_hint_suffix helper, the #[error("... {prefix}")]
annotation on LispError::UnboundTemplateVar /
LispError::NonSymbolUnquoteTarget, the future LSP / REPL /
tatara-check completion-bar projections that key on the typed
marker) inherits the canonical vocabulary through the composition
rather than through a parallel inline table that drifts at the
next vocabulary rename.
Sibling-shape lift to the prior-run AtomKind::label ⊂
SexpShape::label composition (commit 1db697f): both pin the
invariant that a typed-subset enum’s projection on a closed-set
vocabulary is structurally derived from its parent superset’s
projection, not a parallel literal table the type system happens
to not catch when the vocabularies drift.
The bidirectional contract is anchored by tests:
unquote_form_marker_projects_canonical_literal_for_each_variant
pins each variant’s canonical literal so a typo in any arm
fails-loudly,
unquote_form_display_renders_canonical_marker_for_each_variant
pins Display-equals-marker so any #[error("... {prefix}")]
annotation that threads through this projection projects
byte-for-byte,
unquote_form_marker_round_trips_through_from_str pins the
marker ↔ [Self::FromStr] round-trip for every variant in
Self::ALL so the typed surface and the rendered diagnostic
literal cannot drift, and the post-lift composition-routing
pin
unquote_form_marker_routes_through_to_quote_form_prefix_via_composition
asserts pointer-equality between self.marker() and
self.to_quote_form().prefix() for every variant — so a
regression that re-inlines the literals as a parallel match-table
fails the pointer pin even when the rendered bytes still agree
(the inline-literal-table copy lives at a different &'static str
address).
Sourcepub fn to_quote_form(self) -> QuoteForm
pub fn to_quote_form(self) -> QuoteForm
Project the 2-of-4 template-substitution subset back to its
parent crate::ast::QuoteForm superset — the structural
inverse of crate::ast::QuoteForm::as_unquote_form. Returns
the crate::ast::QuoteForm variant whose canonical prefix
string matches this UnquoteForm’s marker:
Self::Unquote → crate::ast::QuoteForm::Unquote,
Self::Splice → crate::ast::QuoteForm::UnquoteSplice.
Total (not Option) because every UnquoteForm IS a
QuoteForm — the 2-of-4 subset is a subset by inclusion. The
dual projection crate::ast::QuoteForm::as_unquote_form
returns Option<UnquoteForm> because the two non-substitution
variants (crate::ast::QuoteForm::Quote and
crate::ast::QuoteForm::Quasiquote) lie outside the
substitution subset.
Round-trip identity: self.to_quote_form().as_unquote_form() == Some(self) for every self: UnquoteForm, pinned by
unquote_form_to_quote_form_round_trips_through_as_unquote_form.
The dual identity qf.as_unquote_form().map(|uf| uf.to_quote_form()) == qf.as_unquote_form().map(|_| qf) holds
by construction (the projection is a section of
crate::ast::QuoteForm::as_unquote_form restricted to its
image — the Unquote/UnquoteSplice variants).
Lifts the (UnquoteForm variant, QuoteForm variant) pairing onto
the typed algebra so consumers that need the parent superset
from a substitution-subset value (the marker lift’s
composition root, the future hint-suffix pretty-printer’s
prefix.to_quote_form().prefix() routing, the future
canonical-form interop tag that wants to route an UnquoteForm
through iac_forge_tag via to_quote_form().iac_forge_tag()
without re-deriving the pairing — now closed at
Self::iac_forge_tag) bind at ONE typed projection
rather than at parallel match arms each site re-derives.
Theory anchor: THEORY.md §V.1 — knowable platform; the subset-to-superset projection becomes a TYPE projection on the substrate algebra. THEORY.md §VI.1 — generation over composition; the (UnquoteForm variant, QuoteForm variant) pairing emerges from this ONE primitive rather than from per-callsite per-variant literals. THEORY.md §II.1 invariant 1 — typed entry; the typed subset-to-superset projection IS a substrate-owned theorem rather than a hand-inlined match-table duplication discipline N sites had to keep in lockstep.
Sourcepub fn wrap(self, inner: Sexp) -> Sexp
pub fn wrap(self, inner: Sexp) -> Sexp
Project the 2-of-4 template-substitution subset marker back into
its matching crate::ast::Sexp wrapper variant applied to
inner — the typed-CONSTRUCT face on the closed-set UnquoteForm
algebra, sibling section-for-retraction of the existing typed-
PROJECT face crate::ast::Sexp::as_unquote on the outer
crate::ast::Sexp algebra. Self::Unquote yields
crate::ast::Sexp::Unquote, Self::Splice yields
crate::ast::Sexp::UnquoteSplice, each boxing inner into the
corresponding tuple-variant constructor
(fn(Box<Sexp>) -> Sexp).
Closes the (construct, project) algebra dual on the closed-set
UnquoteForm algebra — the substitution-subset peer of the
closed-set superset algebra’s already-closed dual pair
(crate::ast::QuoteForm::wrap +
crate::ast::Sexp::as_quote_form). Where the superset’s
wrap reaches all four homoiconic prefix-wrappers and its
projection returns Option<(QuoteForm, &Sexp)> on the outer
crate::ast::Sexp algebra, this subset’s wrap reaches only
the two template-substitution wrappers
(crate::ast::Sexp::Unquote and
crate::ast::Sexp::UnquoteSplice) and its projection sibling
crate::ast::Sexp::as_unquote returns
Option<(UnquoteForm, &Sexp)> — the (construct, project) pair on
the subset algebra is symmetric with the (construct, project)
pair on the superset algebra, each closed at one method per
direction on the respective closed set.
Composition law (forward): self.wrap(inner) == self.to_quote_form().wrap(inner) for every self: UnquoteForm
and every inner: Sexp — routes through the superset’s
crate::ast::QuoteForm::wrap at the single tuple-variant
emission site so the (marker, Sexp::* tuple-variant
constructor) pairing binds at ONE closed-set match on the
superset algebra rather than at a parallel two-arm match table
on this subset. Round-trip law (section-for-retraction with the
soft-projection sibling): self.wrap(inner).as_unquote() == Some((self, &inner)) for every self: UnquoteForm and every
inner: Sexp — the subset’s typed constructor pairs
section-for-retraction with the outer algebra’s soft projection,
and the marker + inner body cross-projection preserves identity
on the substitution-subset closed set. Sibling-shape lift to the
prior-run UnquoteForm::marker ⊂ QuoteForm::prefix composition
(commit 250c001): both pin the invariant that a typed-subset
enum’s projection on a closed-set operation is structurally
derived from its parent superset’s projection through the
canonical to_quote_form composition, not a parallel inline
match-table the type system happens to not catch when the
vocabularies drift.
Pre-lift consumers that had an UnquoteForm marker in hand and
wanted to build a fresh crate::ast::Sexp wrapper had to
spell the two-step composition
uf.to_quote_form().wrap(inner) — a future template rewriter
consuming crate::ast::Sexp::as_unquote’s
Option<(UnquoteForm, &Sexp)> projection and threading a
rewritten inner body back into the matching wrapper on the
substitution-subset closed set (a future
TypedRewriter<UnquoteFormOp> sweep, a future macro-template
canonicalizer that normalizes ,x / ,@x shapes, a future REPL
pretty-printer that emits a fresh substitution wrapper from a
borrowed marker + inner pair) would have re-derived the
.to_quote_form().wrap(_) composition at every callsite. Post-
lift the composition binds at ONE typed-algebra method on the
closed-set UnquoteForm algebra, matching the section-for-
retraction posture the superset’s crate::ast::QuoteForm::wrap
already carries on the outer crate::ast::Sexp algebra. The
(marker, Sexp::* tuple-variant constructor) pairing continues
to live at ONE site on the superset’s wrap closed-set match
(the single tuple-variant emission point the substrate owns),
which is what this subset method routes through — no parallel
match table, no per-arm drift risk on the two-variant closed set.
The crate::ast::Sexp (owned) return type complements
crate::ast::Sexp::as_unquote’s &Sexp (borrowed) —
symmetric with the (crate::ast::QuoteForm::wrap,
crate::ast::Sexp::as_quote_form) asymmetry on the superset
algebra: wrap consumes the inner body to build the new
wrapper, the projection borrows the inner body from the existing
wrapper. The typed Box::new(inner) allocation lives at ONE
site on the superset’s crate::ast::QuoteForm::wrap (the
closed-set tuple-variant emission point), so a future
allocation-policy change (e.g. arena-allocated wrappers for
span-aware crate::ast::Sexp) lands as ONE edit at the
superset’s wrap and propagates through this subset method
byte-for-byte.
Theory anchor: THEORY.md §II.1 invariant 1 — typed entry; the
(UnquoteForm variant, Sexp::* tuple-variant constructor)
pairing binds at ONE typed-algebra method on the subset algebra,
routed through the ONE closed-set match on the superset algebra
the substrate already owns. THEORY.md §II.1 invariant 2 — free
middle; every consumer that has an UnquoteForm marker and
wants to build a wrapper Sexp routes through the SAME typed
method, so a regression that drifts one consumer’s pairing from
the others cannot reach the substrate’s runtime. THEORY.md §V.1
— knowable platform; the typed-construct face becomes a TYPE
projection on the subset algebra sitting next to the typed-
project face crate::ast::Sexp::as_unquote on the outer
crate::ast::Sexp algebra rather than a bare
to_quote_form().wrap(_) two-step composition consumers had to
re-derive per site. THEORY.md §VI.1 — generation over
composition; the (subset marker, wrapper Sexp) pairing emerges
from ONE typed-algebra composition on the subset algebra rather
than from parallel per-consumer per-variant literals.
Frontier inspiration: Racket’s syntax/parse ~or* (~unquote stx) (~unquote-splice stx) pattern paired one-for-one with a
typed constructor face on the same subset shape — the (project,
construct) algebra dual is closed at one method per direction
on Racket’s substitution-subset surface, and UnquoteForm::wrap
/ crate::ast::Sexp::as_unquote is the Rust-typed peer on
the closed-set UnquoteForm algebra with
crate::ast::QuoteForm::wrap standing in for Racket’s typed
dispatch through the superset. MLIR’s typed factory
mlir::OpBuilder::create<UnquoteFamilyOp>(loc, inner) paired
with the projection sibling mlir::dyn_cast<UnquoteFamilyOp>(op)
— the typed factory + typed downcast pair the IR algebra closes
over on every wrapper op subset; UnquoteForm::wrap /
crate::ast::Sexp::as_unquote is the unstructured-Rust peer
on the outer crate::ast::Sexp algebra with the closed-set
UnquoteForm standing in for MLIR’s subset-of-OperationName
taxonomy over the substitution-subset op family.
Sourcepub fn sexp_shape(self) -> SexpShape
pub fn sexp_shape(self) -> SexpShape
Project the 2-of-4 template-substitution subset marker into its
matching SexpShape variant on the outer crate::ast::Sexp
algebra’s twelve-variant shape lattice — Self::Unquote →
SexpShape::Unquote, Self::Splice → SexpShape::UnquoteSplice.
Section peer of SexpShape::as_unquote_form on the 2-of-12
carving that names the template-substitution wrappers; closes the
(embed, project) algebra dual on the UnquoteForm ⊂ SexpShape
typed-shape lattice, sibling of the already-closed
(crate::ast::AtomKind::sexp_shape, SexpShape::as_atom_kind)
dual on the 6-of-12 atomic-payload carving AND
(crate::ast::QuoteForm::sexp_shape, SexpShape::as_quote_form)
dual on the 4-of-12 quote-family carving.
Composition law: self.sexp_shape() == self.to_quote_form().sexp_shape() for every self: UnquoteForm.
The (subset marker, outer SexpShape) pairing binds at ONE
closed-set match on the superset’s
crate::ast::QuoteForm::sexp_shape rather than at a parallel
two-arm inline match table on this subset — matching the posture
Self::marker takes through crate::ast::QuoteForm::prefix
and Self::wrap takes through crate::ast::QuoteForm::wrap.
Round-trip law (section-for-retraction with the outer projection
sibling): self.sexp_shape().as_unquote_form() == Some(self) for
every self: UnquoteForm.
Pre-lift the (UnquoteForm variant, SexpShape variant) pairing had
NO typed projection on this subset algebra — a template rewriter
with an UnquoteForm marker in hand wanting the outer
SexpShape identity (e.g., a future tatara-check predicate
that filters diagnostics to “this rejection was on a template-
substitution wrapper”, a future LSP hover that renders a typed
marker’s outer-shape witness alongside its punctuation, a future
macro-hygiene analyzer that keys on the outer shape of a captured
substitution point) had to spell the two-step composition
uf.to_quote_form().sexp_shape() at every callsite. Post-lift
the composition binds at ONE typed-algebra method on the closed-
set UnquoteForm algebra, and the (embed, project) pair with
SexpShape::as_unquote_form forms an Iso(UnquoteForm, UnquoteShape ⊂ SexpShape) on the substitution-subset carving.
Theory anchor: THEORY.md §V.1 — knowable platform; the (subset
marker, outer shape) pairing becomes a TYPE projection on the
substrate algebra rather than a per-callsite .to_quote_form() .sexp_shape() two-step. THEORY.md §II.1 invariant 2 — free
middle; every consumer that has an UnquoteForm marker and
wants the outer SexpShape routes through the SAME typed
method. THEORY.md §VI.1 — generation over composition; the
pairing emerges from ONE typed-algebra composition on the subset
algebra rather than from parallel per-consumer per-variant
literals.
Frontier inspiration: MLIR’s mlir::OperationName typed
projection from a subset-op-family value into the parent
OperationName taxonomy — the (subset op, taxonomic identity)
pairing lives at ONE typed projection on the subset algebra,
composed through the parent op-family’s typed identity face.
UnquoteForm::sexp_shape is the Rust-typed peer on the closed-
set UnquoteForm algebra with SexpShape standing in for
MLIR’s parent OperationName taxonomy.
Sourcepub fn iac_forge_tag(self) -> &'static str
pub fn iac_forge_tag(self) -> &'static str
Project the 2-of-4 template-substitution subset marker into its
canonical iac-forge interop tag — Self::Unquote →
"unquote", Self::Splice → "unquote-splicing". The
Common-Lisp-canonical tag string crate::ast::QuoteForm::iac_forge_tag
projects on the superset carving, restricted through
Self::to_quote_form to the substitution-subset carving.
Composition law: self.iac_forge_tag() == self.to_quote_form().iac_forge_tag() for every self: UnquoteForm. The body composes Self::to_quote_form (the
typed 2-of-4 subset → superset projection) with
crate::ast::QuoteForm::iac_forge_tag (the canonical 4-of-4
interop-tag projection), so the two &'static str literals live
at ONE canonical site (QuoteForm::iac_forge_tag’s
Unquote/UnquoteSplice arms in ast.rs) — the (subset marker,
canonical iac-forge tag string) pairing binds at ONE closed-set
match on the superset algebra rather than at a parallel two-arm
inline match table on this subset. Matches the posture
Self::marker takes through crate::ast::QuoteForm::prefix,
Self::wrap takes through crate::ast::QuoteForm::wrap,
and Self::sexp_shape takes through
crate::ast::QuoteForm::sexp_shape — the FOURTH
composition-through-to_quote_form axis the closed-set subset
algebra closes.
The &'static str lifetime is load-bearing: every future iac-
forge consumer with an UnquoteForm marker in hand projects
through this method into the canonical 2-element-list head
without an allocation, parallel to how Self::marker projects
the reader-punctuation vocabulary. The tag stays intentionally
disjoint from Self::marker (reader punctuation: "," /
",@") AND from Self::sexp_shape’s
crate::error::SexpShape::label rendering (diagnostic label:
"unquote" / "unquote-splice") at the substitution-subset’s
Splice arm — the CL canonical form REQUIRES the
unquote-splicing spelling, while the substrate’s diagnostic
surface renders unquote-splice. The two projections key the
SAME closed-set on TWO distinct boundaries; consolidating them
would silently break either the iac-forge canonical-form round-
trip OR the operator-facing diagnostic surface. That distinction
is pinned bit-for-bit through the composition law: this method
AGREES with crate::ast::QuoteForm::iac_forge_tag at every
variant AND disagrees with crate::error::SexpShape::label
at the Splice arm through the same closed-set typed algebra.
Pre-lift the (UnquoteForm variant, iac-forge tag) pairing had
NO typed projection on this subset algebra — a future consumer
with an UnquoteForm marker wanting the canonical iac-forge
tag (e.g. a future template rewriter emitting canonical-form
diagnostics keyed on the substitution-subset marker, a future
tatara-check predicate that renders (check-iac-forge-tag ,x) for a substitution-subset value, a future audit-trail
metric jointly labeled by the interop tag on a template-
substitution rejection) had to spell the two-step composition
uf.to_quote_form().iac_forge_tag() at every callsite —
exactly the composition the docstring for Self::wrap
explicitly names as the NEXT deferred sweep this lift picks up.
Post-lift the composition binds at ONE typed-algebra method on
the closed-set UnquoteForm algebra sitting next to the three
prior sibling projections (Self::marker, Self::wrap,
Self::sexp_shape), closing the FOURTH
composition-through-to_quote_form axis on the subset — every
substrate-surface axis the superset algebra carries
(crate::ast::QuoteForm::prefix,
crate::ast::QuoteForm::wrap,
crate::ast::QuoteForm::sexp_shape,
crate::ast::QuoteForm::iac_forge_tag) now has a matching
composition on the substitution subset.
Theory anchor: THEORY.md §V.1 — knowable platform; the (subset
marker, canonical iac-forge tag) pairing becomes a TYPE
projection on the substrate algebra rather than a per-callsite
.to_quote_form().iac_forge_tag() two-step. THEORY.md §II.1
invariant 2 — free middle; every consumer that has an
UnquoteForm marker and wants the canonical iac-forge tag
routes through the SAME typed method. THEORY.md §VI.1 —
generation over composition; the pairing emerges from ONE
typed-algebra composition on the subset algebra rather than
from parallel per-consumer per-variant literals. A future
third template-substitution marker (e.g. ,~ reverse-unquote)
extends Self::ALL + Self::to_quote_form’s dispatch
table in lockstep — rustc-enforced through the closed-set
exhaustiveness — with THIS method inheriting the extension
through the crate::ast::QuoteForm::iac_forge_tag
composition site without a per-site edit.
Frontier inspiration: Racket’s syntax-source-module +
syntax->datum interop chain paired with a substitution-subset
pattern-class projection — the (subset pattern, canonical
interop identity) pairing lives at ONE typed projection on the
subset algebra, composed through the parent syntactic-form
interop identity face. UnquoteForm::iac_forge_tag is the
Rust-typed peer on the closed-set UnquoteForm algebra with
crate::ast::QuoteForm::iac_forge_tag standing in for
Racket’s parent syntactic-form interop identity taxonomy.
MLIR’s mlir::OperationName::getStringRef() typed projection
from a subset-op-family value into the canonical cross-crate
op-identity string — the (subset op, canonical string) pairing
lives at ONE typed projection on the subset algebra, composed
through the parent op-family’s typed identity face.
UnquoteForm::iac_forge_tag is the Rust-typed peer on the
closed-set UnquoteForm algebra with iac_forge_tag standing
in for MLIR’s getStringRef cross-boundary identity face.
Sourcepub fn label(self) -> &'static str
pub fn label(self) -> &'static str
Project the 2-of-4 template-substitution subset marker into its
canonical substrate diagnostic label — Self::Unquote →
"unquote", Self::Splice → "unquote-splice". Feeds the
same SexpShape::label-backed diagnostic surface consumers
reach for on the parent crate::ast::QuoteForm::label
projection, restricted through Self::to_quote_form to the
substitution-subset carving.
Composition law: self.label() == self.to_quote_form().label() for every self: UnquoteForm.
The body composes Self::to_quote_form (the typed 2-of-4
subset → superset projection) with
crate::ast::QuoteForm::label (the canonical 4-of-4
diagnostic-label projection through
crate::ast::QuoteForm::sexp_shape +
SexpShape::label), so the two &'static str literals live
at ONE canonical site (SexpShape::UNQUOTE_LABEL /
SexpShape::UNQUOTE_SPLICE_LABEL in error.rs) — the
(subset marker, canonical diagnostic label) pairing binds at
ONE closed-set match on the superset algebra rather than at a
parallel two-arm inline match table on this subset. Matches
the posture Self::marker takes through
crate::ast::QuoteForm::prefix, Self::wrap takes through
crate::ast::QuoteForm::wrap, Self::sexp_shape takes
through crate::ast::QuoteForm::sexp_shape, and
Self::iac_forge_tag takes through
crate::ast::QuoteForm::iac_forge_tag — the FIFTH
composition-through-to_quote_form axis the closed-set subset
algebra closes.
The &'static str lifetime is load-bearing: every future
diagnostic consumer with an UnquoteForm marker in hand
projects through this method into the canonical
SexpShape-label vocabulary without an allocation, parallel to
how Self::marker projects the reader-punctuation vocabulary
and Self::iac_forge_tag projects the cross-crate iac-forge
vocabulary. The diagnostic label stays intentionally distinct
from Self::marker (reader punctuation: "," / ",@") AND
diverges INTENTIONALLY from Self::iac_forge_tag at the
Splice arm — label renders "unquote-splice" (substrate
diagnostic surface) while iac_forge_tag renders "unquote- splicing" (Common-Lisp canonical form). The typed method
documents the boundary-distinct invariant structurally: a
future “consolidation” that homogenizes the two axes would
have to touch this method explicitly.
Note: #[closed_set(via = "marker")] on the enum’s derive
wires the trait-side tatara_closed_set::ClosedSet::label projection to
Self::marker (the reader-punctuation byte), NOT to this
inherent label (which is the SexpShape-diagnostic label).
The inherent surface takes precedence for direct uf.label()
calls; generic consumers reaching through the trait
(<UnquoteForm as ClosedSet>::label(uf)) still see the marker.
This mirrors crate::ast::QuoteForm::label’s posture on the
parent superset (crate::ast::QuoteForm’s trait label is
wired via #[closed_set(via = "prefix")] to prefix, while
its inherent label returns sexp_shape().label()) — the
UnquoteForm subset now closes the SAME (inherent-diagnostic,
trait-punctuation) split on its subset algebra.
Theory anchor: THEORY.md §V.1 — knowable platform; the
(subset marker, canonical diagnostic label) pairing becomes a
TYPE projection on the substrate algebra rather than a per-
callsite .to_quote_form().label() two-step. THEORY.md §II.1
invariant 2 — free middle; every consumer that has an
UnquoteForm marker and wants the canonical diagnostic label
routes through the SAME typed method. THEORY.md §VI.1 —
generation over composition; the pairing emerges from ONE
typed-algebra composition on the subset algebra rather than
from parallel per-consumer per-variant literals. A future
third template-substitution marker (e.g. ,~ reverse-unquote)
extends Self::ALL + Self::to_quote_form’s dispatch
table in lockstep — rustc-enforced through the closed-set
exhaustiveness — with THIS method inheriting the extension
through the crate::ast::QuoteForm::label composition site
without a per-site edit.
Trait Implementations§
Source§impl Clone for UnquoteForm
impl Clone for UnquoteForm
Source§fn clone(&self) -> UnquoteForm
fn clone(&self) -> UnquoteForm
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl ClosedSet for UnquoteForm
impl ClosedSet for UnquoteForm
Source§const ALL: &'static [Self]
const ALL: &'static [Self]
pub const ALL: [Self; N] whose forced-arity array
literal pins the cardinality at the declaration site.Source§const SET_LABEL: &'static str = "unquote form"
const SET_LABEL: &'static str = "unquote form"
"unknown {SET_LABEL}: {input}" and the typed companion the
trait exposes to generic consumers (metrics taggers, REPL /
LSP completion bars, exhaustive-listing renderers) that want
to name the set without re-deriving the projection at every
call site. Read moreSource§type Unknown = UnknownUnquoteForm
type Unknown = UnknownUnquoteForm
Self::parse_label is handed a non-canonical input. The
substrate-wide convention is the
pub struct UnknownX(pub String) shape with a
#[error("unknown <thing>: {0}")] annotation, but the trait
does not require either — implementors are free to use a
richer carrier (a sum type, a structured diagnostic) as long
as it remains the FromStr::Err for the implementing type.Source§fn label(self) -> &'static str
fn label(self) -> &'static str
&'static str
label — the projection Self::parse_label keys on. Read moreSource§fn make_unknown(s: &str) -> Self::Unknown
fn make_unknown(s: &str) -> Self::Unknown
Self::Unknown(s.to_owned()) for the pub struct UnknownX(pub String) shape. The &str borrow (rather than String) lets
implementors that want to project the input through a
normalization step (a future structured diagnostic carrier
that records both the raw and the normalized form) do so
without forcing the trait surface to materialize an owned
String the implementor doesn’t need.Source§const CARDINALITY: usize = _
const CARDINALITY: usize = _
Self::ALL, surfaced as a compile-time-known usize on
the trait so downstream generic code can bind to it in const
contexts ([T; N] dimensions,
Vec::with_capacity sizing,
bitset widths, per-variant lookup-table shapes) without
re-deriving Self::ALL.len() at every call site. Read moreSource§fn parse_label(s: &str) -> Result<Self, Self::Unknown>
fn parse_label(s: &str) -> Result<Self, Self::Unknown>
Self::label back into the typed variant
— Ok(v) when s matches some v.label() exactly, and
Err(Self::make_unknown(s)) for every other string. Read moreSource§fn find_by_label(s: &str) -> Option<Self>
fn find_by_label(s: &str) -> Option<Self>
Some(v) when s matches some
variant’s Self::label exactly, None for every other
string. Read moreSource§fn contains_label(s: &str) -> bool
fn contains_label(s: &str) -> bool
true iff s matches some variant’s
Self::label exactly, false for every other string. Read moreSource§fn labels() -> Vec<&'static str>
fn labels() -> Vec<&'static str>
Self::label into a
freshly-allocated Vec<&'static str> — Self::ALL’s elements
projected through Self::label, in declaration order. Read moreSource§fn labels_joined(sep: &str) -> String
fn labels_joined(sep: &str) -> String
sep — the
substrate-wide candidate-list-as-string shape consumers thread
into structured-rejection diagnostics (expected one of: nix/flux/lisp/container/aplicacao/guest, allowed: :name, :threshold, targets are kustomization|helm-release|deployment). Read moreSource§fn sorted_labels() -> Vec<&'static str>
fn sorted_labels() -> Vec<&'static str>
Self::labels into ASCII-sort_unstable lexicographic
order — the substrate-wide canonical candidate-list ordering every
per-implementor _all_is_unique_and_complete test inlines a
hand-rolled let mut sorted: Vec<&str> = T::ALL.iter().map(label) .collect(); sorted.sort_unstable(); triple to materialize. Read moreSource§fn sorted_labels_joined(sep: &str) -> String
fn sorted_labels_joined(sep: &str) -> String
sort_unstable
lexicographic order, joined by sep — the substrate-wide
canonical-ordered candidate-list-as-string shape consumers thread
into structured-rejection diagnostics that want alphabetized
rendering (expected one of: aplicacao/container/flux/guest/lisp/nix,
LSP completion bars sorted for humans, tatara-check “did you
mean X?” hints that walk a byte-wise-sorted candidate table). Read moreSource§fn sorted_variants() -> Vec<Self>
fn sorted_variants() -> Vec<Self>
Vec<Self>
ordered by ASCII lexicographic Self::label — the typed-variant
sibling of Self::sorted_labels on the (typed variant,
canonical label) axis of the closed-set candidate-listing surface. Read moreSource§fn sorted_indices() -> Vec<usize>
fn sorted_indices() -> Vec<usize>
Vec<usize> decl-slot
projection of Self::sorted_variants over the closed-set
full-set lex-axis aggregation surface. Every entry i in the
returned vector is the Self::index_of declaration-slot of
some variant in Self::sorted_variants; the returned vector’s
entries are ORDERED by lex position but each entry carries the
DECLARATION slot the variant sits at in Self::ALL, not the
lex slot. Equivalently: the returned vector is a PERMUTATION of
0..T::CARDINALITY — every declaration slot appears exactly
once (paired with clause 96 in assert_closed_set_well_formed)
— and reading the permutation left-to-right walks the closed set
in ASCII-sort_unstable label order. Read moreSource§fn suggest_closest(needle: &str) -> Option<Self>
fn suggest_closest(needle: &str) -> Option<Self>
needle onto the closest variant whose
Self::label sits within the substrate-wide bounded edit
distance — the typed bridge between an unrecognized input and
the “did you mean …?” diagnostic surface. Read moreSource§fn parse_label_with_hint(s: &str) -> Result<Self, (Self::Unknown, Option<Self>)>
fn parse_label_with_hint(s: &str) -> Result<Self, (Self::Unknown, Option<Self>)>
s into the typed variant, threading a typed
Self::suggest_closest hint into the rejection envelope —
the structured-diagnostic surface that composes
Self::parse_label + Self::suggest_closest into ONE
call a downstream LSP / tatara-check consumer takes as
T: ClosedSet. Read moreSource§fn find_by_label_with_hint(s: &str) -> Result<Self, Option<Self>>
fn find_by_label_with_hint(s: &str) -> Result<Self, Option<Self>>
s, threading a typed
Self::suggest_closest hint into the rejection envelope —
the structured-diagnostic surface that composes
Self::find_by_label + Self::suggest_closest into ONE
call a downstream LSP / config-decoder / filter-map consumer
takes as T: ClosedSet WITHOUT paying the
Self::make_unknown carrier allocation
Self::parse_label_with_hint threads on rejection. Read moreSource§fn index_of(self) -> usize
fn index_of(self) -> usize
self onto its zero-indexed position in Self::ALL —
the reverse projection of the Self::ALL slice’s array-index
surface. Closes the (variant → position, position → variant)
bijection with 0..Self::CARDINALITY that every per-variant
lookup-table / bitset / compact-encoding consumer binds to. Read moreSource§fn from_index(i: usize) -> Option<Self>
fn from_index(i: usize) -> Option<Self>
Source§fn first() -> Self
fn first() -> Self
Self::ALL[0] projected onto the trait surface as a
panic-free typed anchor. Closes the (endpoint = 0) corner of
the closed-set endpoint-anchor axis. Read moreSource§fn last() -> Self
fn last() -> Self
Self::ALL[Self::ALL.len() - 1] projected onto the trait
surface as a panic-free typed anchor. Closes the
(endpoint = CARDINALITY - 1) corner of the closed-set
endpoint-anchor axis. Read moreSource§fn first_label() -> &'static str
fn first_label() -> &'static str
T::first().label()
projected onto the trait surface as ONE call. Closes the
(Self, &'static str) return-type axis on the declaration-
axis (head, tail) endpoint-anchor partition at the head slot. Read moreSource§fn last_label() -> &'static str
fn last_label() -> &'static str
T::last().label()
projected onto the trait surface as ONE call. Closes the
(Self, &'static str) return-type axis on the declaration-
axis (head, tail) endpoint-anchor partition at the tail slot. Read moreSource§fn first_index() -> usize
fn first_index() -> usize
T::first().index_of()
projected onto the trait surface as ONE call. Opens the
usize-typed return-type column on the declaration-axis (head,
tail) endpoint-anchor singular partition at the head slot,
mirroring Self::first_label one return-type axis over on
the (&'static str, usize) return-shape column of the
declaration-axis singular endpoint-anchor projection matrix. Read moreSource§fn last_index() -> usize
fn last_index() -> usize
T::last().index_of()
projected onto the trait surface as ONE call. Closes the
(usize, tail) corner of the (return-type × endpoint-direction)
3×2 declaration-axis singular endpoint-anchor return-shape matrix
alongside Self::first (Self, head), Self::last (Self,
tail), Self::first_label (&'static str, head),
Self::last_label (&'static str, tail), and its head-direction
sibling Self::first_index (usize, head). Read moreSource§fn is_first_label(s: &str) -> bool
fn is_first_label(s: &str) -> bool
true
iff s equals Self::first_label, false otherwise. Closes
the (arg-type × endpoint-direction) 2×2 declaration-axis
endpoint-membership matrix at the (&str, head) corner
alongside Self::is_first (Self, head), Self::is_last
(Self, tail), and its tail-direction sibling
Self::is_last_label (&str, tail). Read moreSource§fn is_last_label(s: &str) -> bool
fn is_last_label(s: &str) -> bool
true
iff s equals Self::last_label, false otherwise.
Closes the (&str, tail) corner of the (arg-type ×
endpoint-direction) 2×2 declaration-axis endpoint-membership
matrix alongside Self::is_first (Self, head),
Self::is_last (Self, tail), and Self::is_first_label
(&str, head), completing the (arg-type × endpoint-direction)
2×2 declaration-axis label-and-variant endpoint-membership
square. Read moreSource§fn is_first(self) -> bool
fn is_first(self) -> bool
true when self is Self::first, false otherwise.
Closes the (endpoint-anchor Self-returning, endpoint-membership
bool-returning) return-type axis over the (head, tail) partition
of the declaration-axis endpoint surface. Read moreSource§fn is_last(self) -> bool
fn is_last(self) -> bool
true when self is Self::last, false otherwise.
Closes the (bool, tail) corner of the (return-type ×
endpoint-direction) 2×2 declaration-axis endpoint matrix
alongside Self::is_first. Read moreSource§fn is_first_index(i: usize) -> bool
fn is_first_index(i: usize) -> bool
true
iff the usize argument equals 0 (the declaration-order
head-endpoint’s array slot in Self::ALL), false
otherwise. Closes the (usize, head) corner of the
(arg-type × endpoint-direction) 3×2 declaration-axis
endpoint-membership matrix alongside Self::is_first
(Self, head), Self::is_last (Self, tail),
Self::is_first_label (&str, head), and
Self::is_last_label (&str, tail). Read moreSource§fn is_last_index(i: usize) -> bool
fn is_last_index(i: usize) -> bool
true
iff the usize argument equals T::CARDINALITY - 1 (the
declaration-order tail-endpoint’s array slot in Self::ALL),
false otherwise. Closes the (usize, tail) corner of the
(arg-type × endpoint-direction) 3×2 declaration-axis
endpoint-membership matrix alongside Self::is_first
(Self, head), Self::is_last (Self, tail),
Self::is_first_label (&str, head),
Self::is_last_label (&str, tail), and its head-direction
sibling Self::is_first_index (usize, head), completing
the (arg-type × endpoint-direction) 3×2 declaration-axis
index-and-label-and-variant endpoint-membership rectangle. Read moreSource§fn is_sorted_first_index(i: usize) -> bool
fn is_sorted_first_index(i: usize) -> bool
true
iff the usize argument equals 0 (the lex-order head-
endpoint’s slot in Self::sorted_variants, where the argument
is interpreted as a LEX position — the natural output shape of
Self::sorted_index_of, Self::sorted_next_index,
Self::sorted_prev_index, Self::cycle_sorted_next_index,
and Self::cycle_sorted_prev_index), false otherwise.
Closes the (usize, lex, head) corner of the (arg-type ×
ordering × endpoint-direction) 3×2×2 = 12-corner endpoint-
membership hypercube alongside Self::is_first (Self,
declaration, head), Self::is_last (Self, declaration,
tail), Self::is_sorted_first (Self, lex, head),
Self::is_sorted_last (Self, lex, tail),
Self::is_first_label (&str, declaration, head),
Self::is_last_label (&str, declaration, tail),
Self::is_sorted_first_label (&str, lex, head),
Self::is_sorted_last_label (&str, lex, tail),
Self::is_first_index (usize, declaration, head), and
Self::is_last_index (usize, declaration, tail). Read moreSource§fn is_sorted_last_index(i: usize) -> bool
fn is_sorted_last_index(i: usize) -> bool
true
iff the usize argument equals T::CARDINALITY - 1 (the lex-
order tail-endpoint’s slot in Self::sorted_variants, where
the argument is interpreted as a LEX position — the natural
output shape of Self::sorted_index_of,
Self::sorted_next_index, Self::sorted_prev_index,
Self::cycle_sorted_next_index, and
Self::cycle_sorted_prev_index), false otherwise. Closes
the (usize, lex, tail) corner of the (arg-type × ordering ×
endpoint-direction) 3×2×2 = 12-corner endpoint-membership
hypercube — the TWELFTH and final corner alongside the eleven
enumerated in Self::is_sorted_first_index’s docstring. Read moreSource§fn sorted_first() -> Self
fn sorted_first() -> Self
Self::label under the standard-library
str: Ord ordering, projected onto the trait surface as a
panic-free typed anchor. Closes the (lexicographic-order, head)
corner of the (ordering-axis × endpoint-direction) 2×2
endpoint-anchor matrix — sibling posture to Self::first
(declaration-order, head), Self::last (declaration-order,
tail), and Self::sorted_last (lexicographic-order, tail). Read moreSource§fn sorted_last() -> Self
fn sorted_last() -> Self
Self::label under the standard-library
str: Ord ordering, projected onto the trait surface as a
panic-free typed anchor. Closes the (lexicographic-order, tail)
corner of the (ordering-axis × endpoint-direction) 2×2
endpoint-anchor matrix. Read moreSource§fn sorted_first_label() -> &'static str
fn sorted_first_label() -> &'static str
T::sorted_first().label()
projected onto the trait surface as ONE call. Closes the
(Self, &'static str) return-type axis on the lex-axis
(head, tail) endpoint-anchor partition at the head slot,
completing the (declaration × lex) × (head, tail) × (Self-anchor,
label) 2×2×2 = 8-corner endpoint-anchor return-shape cube
alongside Self::first / Self::last / Self::sorted_first /
Self::sorted_last (the Self-anchor corners), Self::first_label /
Self::last_label (the declaration-axis label corners), and
Self::sorted_last_label (the lex tail-label corner). Read moreSource§fn sorted_last_label() -> &'static str
fn sorted_last_label() -> &'static str
T::sorted_last().label()
projected onto the trait surface as ONE call. Closes the
(Self, &'static str) return-type axis on the lex-axis
(head, tail) endpoint-anchor partition at the tail slot,
completing the (declaration × lex) × (head, tail) × (Self-anchor,
label) 2×2×2 = 8-corner endpoint-anchor return-shape cube. Read moreSource§fn sorted_first_index() -> usize
fn sorted_first_index() -> usize
T::sorted_first().index_of()
projected onto the trait surface as ONE call. Opens the
usize-typed return-type row on the lex-axis (head, tail)
singular endpoint-anchor return-shape column at the head slot,
mirroring Self::sorted_first_label one return-type axis
over on the (&'static str, usize) return-shape column of
the lex-axis singular endpoint-anchor projection matrix AND
mirroring Self::first_index one ordering axis over on the
(declaration, lex) partition of the closed-set singular head-
endpoint decl-slot return-shape column. Read moreSource§fn sorted_last_index() -> usize
fn sorted_last_index() -> usize
T::sorted_last().index_of() projected onto the trait surface
as ONE call. Closes the (usize, lex, tail) corner of the
(return-type × ordering × endpoint-direction) 3×2×2 = 12-corner
singular endpoint-anchor return-shape hypercube alongside the
other eleven corners: Self::first / Self::last /
Self::sorted_first / Self::sorted_last on the Self-anchor
row, Self::first_label / Self::last_label /
Self::sorted_first_label / Self::sorted_last_label on
the label row, and Self::first_index / Self::last_index /
Self::sorted_first_index (this method’s head sibling) on
the decl-slot row. Read moreSource§fn is_sorted_first(self) -> bool
fn is_sorted_first(self) -> bool
true when self is Self::sorted_first, false otherwise.
Closes the (lex, head) corner of the (ordering-axis × endpoint-
direction) 2×2 endpoint-membership matrix alongside
Self::is_first (declaration, head), Self::is_last
(declaration, tail), and Self::is_sorted_last (lex, tail). Read moreSource§fn is_sorted_last(self) -> bool
fn is_sorted_last(self) -> bool
true when self is Self::sorted_last, false otherwise.
Closes the (lex, tail) corner of the (ordering-axis × endpoint-
direction) 2×2 endpoint-membership matrix, completing the
(return-type × ordering × direction) 2×2×2 = 8-corner endpoint
cube alongside Self::is_first, Self::is_last, and
Self::is_sorted_first. Read moreSource§fn is_sorted_first_label(s: &str) -> bool
fn is_sorted_first_label(s: &str) -> bool
true
iff s equals Self::sorted_first_label, false otherwise.
Closes the (&str, lex, head) corner of the (arg-type × ordering
× endpoint-direction) 2×2×2 = 8-corner endpoint-membership
hypercube alongside Self::is_first (Self, declaration, head),
Self::is_last (Self, declaration, tail),
Self::is_sorted_first (Self, lex, head),
Self::is_sorted_last (Self, lex, tail),
Self::is_first_label (&str, declaration, head), and
Self::is_last_label (&str, declaration, tail). Read moreSource§fn is_sorted_last_label(s: &str) -> bool
fn is_sorted_last_label(s: &str) -> bool
true
iff s equals Self::sorted_last_label, false otherwise.
Closes the (&str, lex, tail) corner of the (arg-type ×
ordering × endpoint-direction) 2×2×2 = 8-corner endpoint-
membership hypercube alongside Self::is_first (Self,
declaration, head), Self::is_last (Self, declaration, tail),
Self::is_sorted_first (Self, lex, head),
Self::is_sorted_last (Self, lex, tail),
Self::is_first_label (&str, declaration, head),
Self::is_last_label (&str, declaration, tail), and
Self::is_sorted_first_label (&str, lex, head), completing
the 8-corner hypercube on the closed-set endpoint-membership
surface. Read moreSource§fn is_endpoint(self) -> bool
fn is_endpoint(self) -> bool
true
when self is either Self::first or Self::last,
false on every strictly-interior slot. The endpoint-partition
arm of the (endpoint, interior) boolean-partition axis over the
declaration-axis endpoint surface — one predicate-flavor axis
over from the point-membership pair
(Self::is_first, Self::is_last) and the natural
complement of Self::is_interior. Read moreSource§fn is_interior(self) -> bool
fn is_interior(self) -> bool
true
when self is neither Self::first nor Self::last,
false on both endpoints. The natural complement of
Self::is_endpoint on the (endpoint, interior) boolean-
partition axis over the declaration-axis endpoint surface. Read moreSource§fn is_sorted_endpoint(self) -> bool
fn is_sorted_endpoint(self) -> bool
true
when self is either Self::sorted_first or
Self::sorted_last, false on every strictly-interior lex
slot. The endpoint-partition arm of the (endpoint, interior)
boolean-partition axis over the LEX-axis endpoint surface —
one predicate-flavor axis over from the lex point-membership
pair (Self::is_sorted_first, Self::is_sorted_last) and
the natural complement of Self::is_sorted_interior. Read moreSource§fn is_sorted_interior(self) -> bool
fn is_sorted_interior(self) -> bool
true
when self is neither Self::sorted_first nor
Self::sorted_last, false on both lex endpoints. The
natural complement of Self::is_sorted_endpoint on the
(endpoint, interior) boolean-partition axis over the LEX-axis
endpoint surface. Read moreSource§fn is_endpoint_label(s: &str) -> bool
fn is_endpoint_label(s: &str) -> bool
true iff s equals Self::first_label OR Self::last_label,
false on every strictly-interior canonical label AND on every non-
canonical input. Closes the (&str, declaration, endpoint) corner
of the (arg-type × ordering × predicate-flavor) 2×2×2 = 8-corner
boolean-boundary hypercube alongside Self::is_endpoint (Self,
declaration, endpoint), Self::is_interior (Self, declaration,
interior), Self::is_sorted_endpoint (Self, lex, endpoint), and
Self::is_sorted_interior (Self, lex, interior), opening the
label-shaped column on the boolean-boundary surface one arg-type
axis over from the pre-existing Self-arg (endpoint, interior)
partition. Read moreSource§fn is_interior_label(s: &str) -> bool
fn is_interior_label(s: &str) -> bool
true iff s is a canonical label of a strictly-interior variant
(neither Self::first_label nor Self::last_label),
false on both endpoint labels AND on every non-canonical input.
Closes the (&str, declaration, interior) corner of the (arg-type
× ordering × predicate-flavor) 2×2×2 = 8-corner boolean-boundary
hypercube alongside Self::is_endpoint_label (&str,
declaration, endpoint). Read moreSource§fn is_sorted_endpoint_label(s: &str) -> bool
fn is_sorted_endpoint_label(s: &str) -> bool
true iff s equals Self::sorted_first_label
OR Self::sorted_last_label, false on every strictly-lex-
interior canonical label AND on every non-canonical input.
Closes the (&str, lex, endpoint) corner of the (arg-type ×
ordering × predicate-flavor) 2×2×2 = 8-corner boolean-boundary
hypercube alongside Self::is_endpoint_label (&str,
declaration, endpoint) and Self::is_sorted_endpoint (Self,
lex, endpoint). Read moreSource§fn is_sorted_interior_label(s: &str) -> bool
fn is_sorted_interior_label(s: &str) -> bool
true iff s is a canonical label of a strictly-
lex-interior variant, false on both lex-endpoint labels AND on
every non-canonical input. Closes the (&str, lex, interior)
corner and the final corner of the (arg-type × ordering ×
predicate-flavor) 2×2×2 = 8-corner boolean-boundary hypercube
alongside Self::is_sorted_endpoint_label (&str, lex,
endpoint), Self::is_endpoint_label (&str, declaration,
endpoint), Self::is_interior_label (&str, declaration,
interior), Self::is_endpoint / Self::is_interior on the
declaration Self-arg column, and Self::is_sorted_endpoint
/ Self::is_sorted_interior on the lex Self-arg column. Read moreSource§fn is_endpoint_index(i: usize) -> bool
fn is_endpoint_index(i: usize) -> bool
true iff the usize argument equals 0 (the declaration-order
head-endpoint’s slot in Self::ALL) OR
T::CARDINALITY - 1 (the declaration-order tail-endpoint’s
slot), false on every strictly-interior slot AND on every
out-of-range usize. Opens the usize-arg column of the
(arg-type × ordering × predicate-flavor × endpoint-direction)
hyperbook at the (declaration, endpoint) corner alongside the
pre-existing Self-arg column (Self::is_endpoint,
Self::is_interior, Self::is_sorted_endpoint,
Self::is_sorted_interior) and &str-arg column
(Self::is_endpoint_label, Self::is_interior_label,
Self::is_sorted_endpoint_label, Self::is_sorted_interior_label). Read moreSource§fn is_interior_index(i: usize) -> bool
fn is_interior_index(i: usize) -> bool
true iff i names the array slot of a strictly-interior
variant (neither the declaration-order head slot 0 nor the
declaration-order tail slot T::CARDINALITY - 1), false on
both endpoint slots AND on every out-of-range usize. Closes
the (usize, declaration, interior) corner of the (arg-type ×
ordering × predicate-flavor) 3×2×2 = 12-corner boolean-boundary
hypercube alongside Self::is_endpoint_index (usize,
declaration, endpoint) and the pre-existing eight Self-and-
&str corners. Read moreSource§fn is_sorted_endpoint_index(i: usize) -> bool
fn is_sorted_endpoint_index(i: usize) -> bool
true iff the usize argument equals 0 (the
lex-order head-endpoint’s slot in Self::sorted_variants,
where the argument is interpreted as a LEX position — the
natural output shape of Self::sorted_index_of,
Self::sorted_next_index, Self::sorted_prev_index,
Self::cycle_sorted_next_index, and
Self::cycle_sorted_prev_index) OR T::CARDINALITY - 1 (the
lex-order tail-endpoint’s slot), false on every strictly-lex-
interior lex slot AND on every out-of-range usize. Closes the
(usize, lex, endpoint) corner of the (arg-type × ordering ×
predicate-flavor) 3×2×2 = 12-corner boolean-boundary hypercube
alongside Self::is_endpoint_index (usize, declaration,
endpoint). Read moreSource§fn is_sorted_interior_index(i: usize) -> bool
fn is_sorted_interior_index(i: usize) -> bool
true iff i names the lex slot of a strictly-
lex-interior variant, false on both lex-endpoint slots AND on
every out-of-range usize. Closes the (usize, lex, interior)
corner AND the FINAL corner of the (arg-type × ordering ×
predicate-flavor) 3×2×2 = 12-corner boolean-boundary hypercube
alongside Self::is_sorted_endpoint_index (usize, lex,
endpoint), Self::is_endpoint_index (usize, declaration,
endpoint), Self::is_interior_index (usize, declaration,
interior), and the pre-existing eight Self-and-&str corners. Read moreSource§fn endpoints() -> (Self, Self)
fn endpoints() -> (Self, Self)
(T::first(), T::last()) projected onto the trait surface as
ONE call. Closes the pair-aggregation corner of the closed-set
endpoint-anchor return-shape axis on the DECLARATION side —
the missing middle column between the two scalar endpoint
primitives (Self::first, Self::last) and the collection
aggregation ([Self::variants]). Read moreSource§fn sorted_endpoints() -> (Self, Self)
fn sorted_endpoints() -> (Self, Self)
(T::sorted_first(), T::sorted_last()) projected onto the
trait surface as ONE call. Closes the pair-aggregation corner
of the closed-set endpoint-anchor return-shape axis on the LEX
side. Read moreSource§fn endpoint_labels() -> (&'static str, &'static str)
fn endpoint_labels() -> (&'static str, &'static str)
(T::first().label(), T::last().label()) projected onto the
trait surface as ONE call. Closes the (&'static str, &'static str)
pair-aggregation corner of the closed-set endpoint return-shape
axis on the declaration side. Read moreSource§fn sorted_endpoint_labels() -> (&'static str, &'static str)
fn sorted_endpoint_labels() -> (&'static str, &'static str)
(T::sorted_first().label(), T::sorted_last().label())
projected onto the trait surface as ONE call. Closes the
(&'static str, &'static str) pair-aggregation corner of the
closed-set endpoint return-shape axis on the LEX side. Read moreSource§fn endpoint_indices() -> (usize, usize)
fn endpoint_indices() -> (usize, usize)
(T::first().index_of(), T::last().index_of()) projected onto
the trait surface as ONE call. Opens the (usize, usize) pair-
aggregation row on the closed-set endpoint-anchor pair
return-shape matrix at the (declaration) ordering corner,
mirroring Self::endpoint_labels one return-type axis over on
the ((&'static str, &'static str), (usize, usize)) return-
shape column of the pair-endpoint aggregation matrix AND
mirroring Self::first_index + Self::last_index one
aggregation-shape axis over on the (singular scalar, pair-tuple)
partition of the closed-set declaration-axis endpoint-decl-slot
return-shape column. Read moreSource§fn sorted_endpoint_indices() -> (usize, usize)
fn sorted_endpoint_indices() -> (usize, usize)
(T::sorted_first().index_of(), T::sorted_last().index_of())
projected onto the trait surface as ONE call. Closes the
(return-type × ordering) 3×2 = 6-corner pair-endpoint
aggregation matrix at the (usize, lex) corner alongside the
other five corners: Self::endpoints +
Self::sorted_endpoints on the (Self, Self) row,
Self::endpoint_labels + Self::sorted_endpoint_labels on
the (&'static str, &'static str) row, and
Self::endpoint_indices (this method’s declaration-axis
sibling) on the (usize, usize) row. Read moreSource§fn endpoint_labels_joined(sep: &str) -> String
fn endpoint_labels_joined(sep: &str) -> String
String
joined by sep — the joined-String sibling of
Self::endpoint_labels one return-shape axis over on the
(tuple, String) partition of the closed-set declaration-axis
endpoint-label return-shape axis. Read moreSource§fn sorted_endpoint_labels_joined(sep: &str) -> String
fn sorted_endpoint_labels_joined(sep: &str) -> String
String joined
by sep — the alphabetized endpoint-label-as-string sibling
of Self::endpoint_labels_joined one ordering axis over on
the (declaration, lex) partition of the closed-set endpoint-
label-as-string surface. Read moreSource§fn interior() -> Vec<Self>
fn interior() -> Vec<Self>
Vec<Self> complement of Self::endpoints over the closed-
set boundary-partition axis. Every variant v in the returned
vector satisfies <Self as ClosedSet>::is_interior(v) == true
(v is neither Self::first nor Self::last); the
declaration order of Self::ALL is preserved verbatim. Read moreSource§fn sorted_interior() -> Vec<Self>
fn sorted_interior() -> Vec<Self>
Vec<Self> complement of Self::sorted_endpoints over the
closed-set lex-boundary-partition axis. Every variant v in
the returned vector satisfies
<Self as ClosedSet>::is_sorted_interior(v) == true (v is
neither Self::sorted_first nor Self::sorted_last); the
lex order of Self::sorted_variants is preserved verbatim. Read moreSource§fn interior_labels() -> Vec<&'static str>
fn interior_labels() -> Vec<&'static str>
Vec<&'static str> label projection of Self::interior over
the closed-set declaration-axis boundary-partition surface.
Every label s in the returned vector is the canonical
Self::label rendering of some strictly-interior variant
(<Self as ClosedSet>::is_interior(v) == true for the sourcing
variant, so s is neither Self::first’s label nor
Self::last’s label); the declaration order of
Self::interior is preserved verbatim. Read moreSource§fn sorted_interior_labels() -> Vec<&'static str>
fn sorted_interior_labels() -> Vec<&'static str>
Vec<&'static str> label projection of Self::sorted_interior
over the closed-set lex-axis boundary-partition surface. Every
label s in the returned vector is the canonical
Self::label rendering of some strictly-lex-interior variant
(<Self as ClosedSet>::is_sorted_interior(v) == true for the
sourcing variant, so s is neither Self::sorted_first’s
label nor Self::sorted_last’s label); the lex order of
Self::sorted_interior is preserved verbatim. Read moreSource§fn interior_labels_joined(sep: &str) -> String
fn interior_labels_joined(sep: &str) -> String
String joined by sep — the substrate-wide alphabetized-
vs-declaration interior-label-as-string surface consumers thread
into structured diagnostics that want the boundary-stripped
candidate list in a caller-supplied separator style
(interior: beta, gamma, delta, middle-only: beta/gamma, an
interior-only expected one of the middle kinds: … metrics
tag whose surface must NOT leak the two endpoint anchors). Read moreSource§fn sorted_interior_labels_joined(sep: &str) -> String
fn sorted_interior_labels_joined(sep: &str) -> String
String joined by sep — the alphabetized interior-label-as-
string sibling of Self::interior_labels_joined one
ordering axis over on the (declaration, lex) partition of the
closed-set interior-label-as-string surface. Read moreSource§fn interior_indices() -> Vec<usize>
fn interior_indices() -> Vec<usize>
Vec<usize> decl-slot projection of Self::interior over the
closed-set declaration-axis boundary-partition surface. Every
index i in the returned vector is the Self::index_of
declaration-slot of some strictly-interior variant v in
Self::interior (<Self as ClosedSet>::is_interior(v) == true,
equivalently <Self as ClosedSet>::is_interior_index(i) == true),
so i names neither 0 (the decl-head endpoint slot) nor
Self::CARDINALITY - 1 (the decl-tail endpoint slot); the
declaration order of Self::interior is preserved verbatim. Read moreSource§fn sorted_interior_indices() -> Vec<usize>
fn sorted_interior_indices() -> Vec<usize>
Vec<usize>
decl-slot projection of Self::sorted_interior over the
closed-set lex-axis boundary-partition surface. Every index i
in the returned vector is the Self::index_of declaration-slot
of some strictly-lex-interior variant v in
Self::sorted_interior (<Self as ClosedSet>::is_sorted_interior(v) == true, equivalently <Self as ClosedSet>::is_sorted_interior_index(<Self as ClosedSet>::sorted_index_of(v)) == true), so i names neither the decl slot of
Self::sorted_first nor the decl slot of Self::sorted_last;
the lex order of Self::sorted_interior is preserved verbatim
(the returned vector’s entries are ORDERED by lex position but
each entry carries the DECLARATION slot the variant sits at in
Self::ALL, not the lex slot — the same usize carrier
Self::interior_indices returns one ordering axis over). Read moreSource§fn label_at(i: usize) -> Option<&'static str>
fn label_at(i: usize) -> Option<&'static str>
Self::label at declaration-order
position i in Self::ALL, or None if
i >= Self::CARDINALITY. Read moreSource§fn index_of_label(s: &str) -> Option<usize>
fn index_of_label(s: &str) -> Option<usize>
usize position in Self::ALL
of the variant labelled s, or None if s matches no
variant’s Self::label. Read moreSource§fn index_of_label_with_hint(s: &str) -> Result<usize, Option<Self>>
fn index_of_label_with_hint(s: &str) -> Result<usize, Option<Self>>
Self::index_of_label — the zero-
allocation structured decode of s into a declaration-order
index, threading a typed Self::suggest_closest hint into the
rejection envelope. Peer of Self::find_by_label_with_hint
on the (usize-typed direct projection) axis of the closed-set
structured-decode surface: where Self::find_by_label_with_hint
returns the typed variant on match, this method projects that
variant through Self::index_of so the caller gets the
declaration-order slot directly. Read moreSource§fn parse_index_of_label_with_hint(
s: &str,
) -> Result<usize, (Self::Unknown, Option<Self>)>
fn parse_index_of_label_with_hint( s: &str, ) -> Result<usize, (Self::Unknown, Option<Self>)>
s into a declaration-
order Self::ALL index THREADING a typed
Self::suggest_closest hint alongside the substrate-wide
Self::Unknown carrier on the reject arm — the (hint) sibling
of Self::parse_index_of_label one hint-axis over on the
(allocating carrier, &str → usize decl-order decode) surface
AND the (usize-typed direct projection) sibling of
Self::parse_label_with_hint one return-type-axis over on the
(allocating carrier, with-hint) surface. Where
Self::parse_index_of_label returns
Result<usize, Self::Unknown> (no hint threading), this method
widens the reject arm to (Self::Unknown, Option<Self>) so a
downstream ?-operator-chained decoder gets BOTH the substrate-
wide unknown {SET_LABEL}: {input} carrier AND the typed
Self::suggest_closest near-miss slot through ONE call. Read moreSource§fn sorted_index_of(self) -> usize
fn sorted_index_of(self) -> usize
Self::index_of one
ordering-axis over — the direct (typed variant → usize
lexicographic-order index) projection through the closed set,
keyed on Self::label under the standard-library str: Ord
ordering. Returns the position v would occupy in
Self::sorted_variants — equivalently, the count of canonical
labels strictly less than Self::label(self) under str::cmp. Read moreSource§fn from_sorted_index(i: usize) -> Option<Self>
fn from_sorted_index(i: usize) -> Option<Self>
i in
Self::sorted_variants, or None if i >= Self::CARDINALITY. Read moreSource§fn sorted_label_at(i: usize) -> Option<&'static str>
fn sorted_label_at(i: usize) -> Option<&'static str>
Self::label at lexicographic-order
position i in Self::sorted_labels, or None if
i >= Self::CARDINALITY. Read moreSource§fn sorted_index_of_label(s: &str) -> Option<usize>
fn sorted_index_of_label(s: &str) -> Option<usize>
usize position of the variant
labelled s, or None if s matches no variant’s
Self::label. Read moreSource§fn sorted_index_of_label_with_hint(s: &str) -> Result<usize, Option<Self>>
fn sorted_index_of_label_with_hint(s: &str) -> Result<usize, Option<Self>>
Self::sorted_index_of_label — the zero-
allocation structured decode of s into a lexicographic-order
index, threading a typed Self::suggest_closest hint into the
rejection envelope. Peer of Self::index_of_label_with_hint
one ordering-axis over on the (usize-typed direct projection
with hint) surface: where Self::index_of_label_with_hint
projects the accept-arm variant through Self::index_of
(declaration order), this method projects it through
Self::sorted_index_of (lex order), so the caller gets the
canonical alphabetic-order slot directly. Read moreSource§fn parse_sorted_index_of_label(s: &str) -> Result<usize, Self::Unknown>
fn parse_sorted_index_of_label(s: &str) -> Result<usize, Self::Unknown>
s into a
lexicographic-order index, threading the substrate-wide
unknown {SET_LABEL}: {input} Self::Unknown carrier
through the reject arm — the ordering-axis sibling of
Self::parse_index_of_label one ordering-axis over on the
(allocating-carrier &str → usize decode, no-hint) surface.
Where Self::parse_index_of_label projects the accept-arm
variant through Self::index_of (declaration order), this
method projects it through Self::sorted_index_of (lex
order), so the caller gets the canonical alphabetic-order slot
directly through ONE call the substrate’s diagnostic engine
binds to. Read moreSource§fn parse_sorted_index_of_label_with_hint(
s: &str,
) -> Result<usize, (Self::Unknown, Option<Self>)>
fn parse_sorted_index_of_label_with_hint( s: &str, ) -> Result<usize, (Self::Unknown, Option<Self>)>
s into a
lexicographic-order Self::ALL index THREADING a typed
Self::suggest_closest hint alongside the substrate-wide
Self::Unknown carrier on the reject arm — the (ordering)
sibling of Self::parse_index_of_label_with_hint one
ordering-axis over on the (allocating carrier, &str → usize
with-hint) surface AND the (side-effect) sibling of
Self::sorted_index_of_label_with_hint one side-effect axis
over on the (&str → usize lex-order with-hint) surface AND
the (hint) sibling of Self::parse_sorted_index_of_label one
hint-axis over on the (allocating carrier, &str → usize
lex-order) surface. Where Self::parse_index_of_label_with_hint
projects the accept-arm variant through Self::index_of
(declaration order), this method projects it through
Self::sorted_index_of (lex order), so the caller gets the
canonical alphabetic-order slot AND the substrate-wide
Self::Unknown carrier AND the typed
Self::suggest_closest near-miss slot through ONE call the
substrate’s diagnostic engine binds to. Read moreSource§fn next_label(self) -> Option<&'static str>
fn next_label(self) -> Option<&'static str>
&'static str LABEL of the declaration-order
neighbor immediately AFTER self in Self::ALL — the label
of Self::next projected through Self::label, or None
when self is the declaration-order tail-endpoint. Read moreSource§fn prev_label(self) -> Option<&'static str>
fn prev_label(self) -> Option<&'static str>
&'static str LABEL of the declaration-order
neighbor immediately BEFORE self in Self::ALL — the
label of Self::prev projected through Self::label, or
None when self is the declaration-order head-endpoint. Read moreSource§fn next_index(self) -> Option<usize>
fn next_index(self) -> Option<usize>
usize DECLARATION-ORDER INDEX of the neighbor immediately
AFTER self in Self::ALL — the position of Self::next
projected through Self::index_of, or None when self
is the declaration-order tail-endpoint. Read moreSource§fn prev_index(self) -> Option<usize>
fn prev_index(self) -> Option<usize>
usize DECLARATION-ORDER INDEX of the neighbor immediately
BEFORE self in Self::ALL — the position of Self::prev
projected through Self::index_of, or None when self
is the declaration-order head-endpoint. Read moreSource§fn sorted_next_index(self) -> Option<usize>
fn sorted_next_index(self) -> Option<usize>
usize LEXICOGRAPHIC-ORDER INDEX of the neighbor immediately
AFTER self in Self::sorted_variants — the lex position of
Self::sorted_next projected through Self::sorted_index_of,
or None when self is the lex-tail-endpoint. Read moreSource§fn sorted_prev_index(self) -> Option<usize>
fn sorted_prev_index(self) -> Option<usize>
usize LEXICOGRAPHIC-ORDER INDEX of the neighbor immediately
BEFORE self in Self::sorted_variants — the lex position of
Self::sorted_prev projected through
Self::sorted_index_of, or None when self is the lex-
head-endpoint. Read moreSource§fn sorted_next_label(self) -> Option<&'static str>
fn sorted_next_label(self) -> Option<&'static str>
&'static str LABEL of the lexicographic-order
neighbor immediately AFTER self in Self::sorted_variants —
the label of Self::sorted_next projected through
Self::label, or None when self is the lex-tail-endpoint. Read moreSource§fn sorted_prev_label(self) -> Option<&'static str>
fn sorted_prev_label(self) -> Option<&'static str>
&'static str LABEL of the lexicographic-order
neighbor immediately BEFORE self in Self::sorted_variants —
the label of Self::sorted_prev projected through
Self::label, or None when self is the lex-head-endpoint. Read moreSource§fn sorted_next(self) -> Option<Self>
fn sorted_next(self) -> Option<Self>
self in
Self::sorted_variants — Some(Self::sorted_variants()[ self.sorted_index_of() + 1]) when self is not the lex-tail,
None otherwise. Read moreSource§fn sorted_prev(self) -> Option<Self>
fn sorted_prev(self) -> Option<Self>
self in
Self::sorted_variants — Some(Self::sorted_variants()[ self.sorted_index_of() - 1]) when self is not the lex-head,
None otherwise. Read moreSource§fn cycle_next(self) -> Self
fn cycle_next(self) -> Self
self in
Self::ALL, WRAPPING to Self::first at the tail —
self.next().unwrap_or(Self::first()). Returns Self,
never Option<Self>: the wrapping arm folds the tail-
endpoint boundary onto the head-endpoint anchor rather than
leaving the None the bounded-neighbor axis returns. Read moreSource§fn cycle_prev(self) -> Self
fn cycle_prev(self) -> Self
self in
Self::ALL, WRAPPING to Self::last at the head —
self.prev().unwrap_or(Self::last()). Returns Self, never
Option<Self>: the wrapping arm folds the head-endpoint
boundary onto the tail-endpoint anchor rather than leaving the
None the bounded-neighbor axis returns. Read moreSource§fn cycle_sorted_next(self) -> Self
fn cycle_sorted_next(self) -> Self
self in
Self::sorted_variants, WRAPPING to Self::sorted_first at
the lex tail — self.sorted_next().unwrap_or(Self::sorted_first()).
Returns Self, never Option<Self>: the wrapping arm folds
the lex-tail-endpoint boundary onto the lex-head-endpoint anchor
rather than leaving the None the bounded-lex-neighbor axis
returns. Read moreSource§fn cycle_sorted_prev(self) -> Self
fn cycle_sorted_prev(self) -> Self
self in
Self::sorted_variants, WRAPPING to Self::sorted_last at
the lex head — self.sorted_prev().unwrap_or(Self::sorted_last()).
Returns Self, never Option<Self>: the wrapping arm folds
the lex-head-endpoint boundary onto the lex-tail-endpoint anchor
rather than leaving the None the bounded-lex-neighbor axis
returns. Read moreSource§fn cycle_next_label(self) -> &'static str
fn cycle_next_label(self) -> &'static str
&'static str LABEL of the declaration-order
neighbor immediately AFTER self in Self::ALL, WRAPPING
to Self::first_label at the tail — the label of
Self::cycle_next projected through Self::label. Returns
&'static str, never Option<&'static str>: the wrapping arm
folds the tail-endpoint boundary onto the head-endpoint anchor
label rather than leaving the None the bounded-neighbor-
label axis returns. Read moreSource§fn cycle_prev_label(self) -> &'static str
fn cycle_prev_label(self) -> &'static str
&'static str LABEL of the declaration-order
neighbor immediately BEFORE self in Self::ALL, WRAPPING
to Self::last_label at the head — the label of
Self::cycle_prev projected through Self::label. Returns
&'static str, never Option<&'static str>. Read moreSource§fn cycle_sorted_next_label(self) -> &'static str
fn cycle_sorted_next_label(self) -> &'static str
&'static str LABEL of the lexicographic-order
neighbor immediately AFTER self in Self::sorted_variants,
WRAPPING to Self::sorted_first_label at the lex tail — the
label of Self::cycle_sorted_next projected through
Self::label. Returns &'static str, never
Option<&'static str>. Read moreSource§fn cycle_sorted_prev_label(self) -> &'static str
fn cycle_sorted_prev_label(self) -> &'static str
&'static str LABEL of the lexicographic-order
neighbor immediately BEFORE self in Self::sorted_variants,
WRAPPING to Self::sorted_last_label at the lex head — the
label of Self::cycle_sorted_prev projected through
Self::label. Returns &'static str, never
Option<&'static str>. Read moreSource§fn cycle_next_index(self) -> usize
fn cycle_next_index(self) -> usize
usize DECLARATION-ORDER INDEX of the neighbor immediately
AFTER self in Self::ALL, WRAPPING to 0 at the tail — the
declaration-order position of Self::cycle_next projected
through Self::index_of. Returns usize, never
Option<usize>: the wrapping arm folds the tail-endpoint
boundary onto the head-index-anchor 0 rather than leaving the
None the bounded-neighbor-index axis returns. Read moreSource§fn cycle_prev_index(self) -> usize
fn cycle_prev_index(self) -> usize
usize DECLARATION-ORDER INDEX of the neighbor immediately
BEFORE self in Self::ALL, WRAPPING to T::CARDINALITY - 1
at the head — the declaration-order position of
Self::cycle_prev projected through Self::index_of.
Returns usize, never Option<usize>: the wrapping arm folds
the head-endpoint boundary onto the tail-index-anchor rather
than leaving the None the bounded-neighbor-index axis
returns. Read moreSource§fn cycle_sorted_next_index(self) -> usize
fn cycle_sorted_next_index(self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the neighbor immediately
AFTER self in Self::sorted_variants, WRAPPING to 0 at
the lex tail — the lex position of Self::cycle_sorted_next
projected through Self::sorted_index_of. Returns usize,
never Option<usize>: the wrapping arm folds the lex-tail-
endpoint boundary onto the lex-head-index-anchor 0 rather than
leaving the None the bounded-lex-neighbor-index axis returns. Read moreSource§fn cycle_sorted_prev_index(self) -> usize
fn cycle_sorted_prev_index(self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the neighbor immediately
BEFORE self in Self::sorted_variants, WRAPPING to
T::CARDINALITY - 1 at the lex head — the lex position of
Self::cycle_sorted_prev projected through
Self::sorted_index_of. Returns usize, never
Option<usize>: the wrapping arm folds the lex-head-endpoint
boundary onto the lex-tail-index-anchor rather than leaving the
None the bounded-lex-neighbor-index axis returns. Read moreSource§fn precedes(self, other: Self) -> bool
fn precedes(self, other: Self) -> bool
true iff self appears strictly before other in
Self::ALL’s declaration order, false on equality or when
self appears strictly after other. The binary peer of every
pre-existing UNARY declaration-axis endpoint predicate
(Self::is_first, Self::is_last, Self::is_endpoint,
Self::is_interior, Self::is_first_label,
Self::is_last_label, Self::is_endpoint_label,
Self::is_interior_label, Self::is_first_index,
Self::is_last_index, Self::is_endpoint_index,
Self::is_interior_index) — those methods answer “where does
this ONE variant sit in the declaration axis,” this method
answers “which of these TWO variants sits earlier in the
declaration axis.” Opens the (self, other) pairwise-comparison
axis on the closed-set surface at the declaration-order
strict-less-than corner. Read moreSource§fn succeeds(self, other: Self) -> bool
fn succeeds(self, other: Self) -> bool
true iff self appears strictly AFTER other in
Self::ALL’s declaration order, false on equality or when
self appears strictly before other. The direction-complement
arm of Self::precedes on the (forward, backward) axis of
the declaration-order pairwise-comparison surface. Read moreSource§fn sorted_precedes(self, other: Self) -> bool
fn sorted_precedes(self, other: Self) -> bool
true
iff self appears strictly before other in lexicographic
order over Self::label’s projection, false on equality
or when self appears strictly after other. The
lex-ordering peer of Self::precedes on the (declaration,
lex) ordering axis of the pairwise-comparison surface. Read moreSource§fn sorted_succeeds(self, other: Self) -> bool
fn sorted_succeeds(self, other: Self) -> bool
true
iff self appears strictly AFTER other in lexicographic
order over Self::label’s projection, false on equality
or when self appears strictly before other. The
direction-complement of Self::sorted_precedes on the
(forward, backward) direction axis of the lex-ordering
pairwise-comparison surface. Read moreSource§fn precedes_or_equal(self, other: Self) -> bool
fn precedes_or_equal(self, other: Self) -> bool
true iff self appears before OR is equal to other in
Self::ALL’s declaration order, false when self appears
strictly after other. The strictness-complement of
Self::precedes on the (strict, non-strict) axis of the
declaration-order pairwise-comparison surface. Read moreSource§fn succeeds_or_equal(self, other: Self) -> bool
fn succeeds_or_equal(self, other: Self) -> bool
true iff self appears AFTER OR is equal to other in
Self::ALL’s declaration order, false when self appears
strictly before other. The direction-complement arm of
Self::precedes_or_equal on the (forward, backward) axis of
the declaration-order non-strict pairwise-comparison surface. Read moreSource§fn sorted_precedes_or_equal(self, other: Self) -> bool
fn sorted_precedes_or_equal(self, other: Self) -> bool
true
iff self appears before OR is equal to other in lexicographic
order over Self::label’s projection, false when self
appears strictly after other. The lex-ordering peer of
Self::precedes_or_equal on the (declaration, lex) ordering
axis of the non-strict pairwise-comparison surface. Read moreSource§fn sorted_succeeds_or_equal(self, other: Self) -> bool
fn sorted_succeeds_or_equal(self, other: Self) -> bool
true
iff self appears AFTER OR is equal to other in lexicographic
order over Self::label’s projection, false when self
appears strictly before other. The direction-complement of
Self::sorted_precedes_or_equal on the (forward, backward)
direction axis of the lex-ordering non-strict pairwise-
comparison surface. Read moreSource§fn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
self and other in Self::ALL’s declaration
order. Returns self when self.precedes_or_equal(other) (so
ties fold to self, matching Rust’s core::cmp::min tie-
break convention), returns other otherwise. Read moreSource§fn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
self and other in Self::ALL’s declaration
order. Returns self when self.succeeds_or_equal(other)
(ties fold to self, mirroring Self::min’s tie-break-
left convention across the (min, max) axis), returns
other otherwise. The direction-complement arm of
Self::min on the (min, max) axis of the declaration-order
binary pairwise-selection surface. Read moreSource§fn sorted_min(self, other: Self) -> Self
fn sorted_min(self, other: Self) -> Self
self and other under Self::label’s
projection into ASCII lexicographic order. Returns self
when self.sorted_precedes_or_equal(other) (ties fold to
self), returns other otherwise. The lex-ordering peer of
Self::min on the (declaration, lex) ordering axis of the
binary pairwise-selection surface. Read moreSource§fn sorted_max(self, other: Self) -> Self
fn sorted_max(self, other: Self) -> Self
self and other under Self::label’s
projection into ASCII lexicographic order. Returns self
when self.sorted_succeeds_or_equal(other) (ties fold to
self), returns other otherwise. Closes the (ordering ×
direction) 2×2 = 4-corner binary pairwise-selection matrix on
the closed-set surface at the (lex-order, max) corner —
sibling posture to Self::sorted_min one direction axis
over on the lex arm AND to Self::max one ordering axis
over on the max arm. Read moreSource§fn min_label(self, other: Self) -> &'static str
fn min_label(self, other: Self) -> &'static str
&'static str LABEL of the declaration-order
binary pairwise-MIN projection of self and other — the
label of Self::min projected through Self::label.
Returns &'static str, never Option<&'static str>: the
binary min projection is TOTAL on every operand pair, and
every variant carries a canonical label. Read moreSource§fn max_label(self, other: Self) -> &'static str
fn max_label(self, other: Self) -> &'static str
&'static str LABEL of the declaration-order
binary pairwise-MAX projection of self and other — the
label of Self::max projected through Self::label.
Returns &'static str, never Option<&'static str>. Read moreSource§fn sorted_min_label(self, other: Self) -> &'static str
fn sorted_min_label(self, other: Self) -> &'static str
&'static str LABEL of the lex-order binary
pairwise-MIN projection of self and other — the label of
Self::sorted_min projected through Self::label.
Returns &'static str, never Option<&'static str>. Read moreSource§fn sorted_max_label(self, other: Self) -> &'static str
fn sorted_max_label(self, other: Self) -> &'static str
&'static str LABEL of the lex-order binary
pairwise-MAX projection of self and other — the label of
Self::sorted_max projected through Self::label.
Returns &'static str, never Option<&'static str>. Read moreSource§fn min_index(self, other: Self) -> usize
fn min_index(self, other: Self) -> usize
usize DECLARATION-ORDER INDEX of the declaration-order
binary pairwise-MIN projection of self and other — the
declaration-order position of Self::min projected through
Self::index_of. Returns usize, never Option<usize>:
the binary min projection is TOTAL on every operand pair, and
every variant carries a declaration-order slot. Read moreSource§fn max_index(self, other: Self) -> usize
fn max_index(self, other: Self) -> usize
usize DECLARATION-ORDER INDEX of the declaration-order
binary pairwise-MAX projection of self and other — the
declaration-order position of Self::max projected through
Self::index_of. Returns usize, never Option<usize>. Read moreSource§fn sorted_min_index(self, other: Self) -> usize
fn sorted_min_index(self, other: Self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the lex-order binary
pairwise-MIN projection of self and other — the lex position
of Self::sorted_min projected through
Self::sorted_index_of. Returns usize, never
Option<usize>. Read moreSource§fn sorted_max_index(self, other: Self) -> usize
fn sorted_max_index(self, other: Self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the lex-order binary
pairwise-MAX projection of self and other — the lex position
of Self::sorted_max projected through
Self::sorted_index_of. Returns usize, never
Option<usize>. Read moreSource§fn min_of(items: &[Self]) -> Option<Self>
fn min_of(items: &[Self]) -> Option<Self>
items under Self::ALL’s declaration order, or
None when items is empty. Folds Self::min over
items from left via Iterator::reduce: the singleton case
returns Some(items[0]), the k-length case returns
Some(items.iter().copied().reduce(min).unwrap()). The
arity-N opener on the closed-set surface past the exhaustively-
closed 12-corner binary pairwise-SELECTION hypercube (95)+(96)+
(97)+(98)+(99)+(100) — opens the arity axis one step further
from binary pairwise-selection to N-ary variadic reduction over
a slice. Read moreSource§fn max_of(items: &[Self]) -> Option<Self>
fn max_of(items: &[Self]) -> Option<Self>
items under Self::ALL’s declaration order, or
None when items is empty. Folds Self::max over
items from left via Iterator::reduce. Read moreSource§fn sorted_min_of(items: &[Self]) -> Option<Self>
fn sorted_min_of(items: &[Self]) -> Option<Self>
items under Self::label’s projection into ASCII
lexicographic order, or None when items is empty. Folds
Self::sorted_min over items from left via
Iterator::reduce. Read moreSource§fn sorted_max_of(items: &[Self]) -> Option<Self>
fn sorted_max_of(items: &[Self]) -> Option<Self>
items under Self::label’s projection into ASCII
lexicographic order, or None when items is empty. Folds
Self::sorted_max over items from left via
Iterator::reduce. Read moreSource§fn min_label_of(items: &[Self]) -> Option<&'static str>
fn min_label_of(items: &[Self]) -> Option<&'static str>
&'static str LABEL of the declaration-order
N-ARY MIN projection of items — the label of Self::min_of
projected through Self::label, or None when items is
empty. The label-return-shape peer of Self::min_of one
return-shape axis over on the N-ary variadic-reduction surface,
AND the N-ary-arity peer of Self::min_label one arity level
up. Opens the label-return column of the (return-shape × ordering
× direction) 3×2×2 = 12-corner N-ary variadic-reduction hypercube
past the exhaustively-closed 4-corner Self-return face
Self::min_of / Self::max_of / Self::sorted_min_of /
Self::sorted_max_of — the N-ary counterpart of the binary
pairwise-selection hypercube’s own return-shape column
Self::min_label / Self::max_label /
Self::sorted_min_label / Self::sorted_max_label one
arity level down. Read moreSource§fn max_label_of(items: &[Self]) -> Option<&'static str>
fn max_label_of(items: &[Self]) -> Option<&'static str>
&'static str LABEL of the declaration-order
N-ARY MAX projection of items — the label of Self::max_of
projected through Self::label, or None when items is
empty. Read moreSource§fn sorted_min_label_of(items: &[Self]) -> Option<&'static str>
fn sorted_min_label_of(items: &[Self]) -> Option<&'static str>
&'static str LABEL of the lex-order N-ARY MIN
projection of items — the label of Self::sorted_min_of
projected through Self::label, or None when items is
empty. Read moreSource§fn sorted_max_label_of(items: &[Self]) -> Option<&'static str>
fn sorted_max_label_of(items: &[Self]) -> Option<&'static str>
&'static str LABEL of the lex-order N-ARY MAX
projection of items — the label of Self::sorted_max_of
projected through Self::label, or None when items is
empty. Read moreSource§fn min_index_of(items: &[Self]) -> Option<usize>
fn min_index_of(items: &[Self]) -> Option<usize>
usize DECLARATION-ORDER INDEX of the declaration-order
N-ARY MIN projection of items — the declaration-order position
of Self::min_of projected through Self::index_of, or
None when items is empty. The index-return-shape peer of
Self::min_of one return-shape axis over on the N-ary
variadic-reduction surface, AND the N-ary-arity peer of
Self::min_index one arity level up. Opens the index-return
column of the (return-shape × ordering × direction) 3×2×2 =
12-corner N-ary variadic-reduction hypercube past the pre-
existing Self-return 4-corner face Self::min_of /
Self::max_of / Self::sorted_min_of / Self::sorted_max_of
AND the label-return 4-corner face Self::min_label_of /
Self::max_label_of / Self::sorted_min_label_of /
Self::sorted_max_label_of — the N-ary counterpart of the
binary pairwise-selection hypercube’s own index-return column
Self::min_index / Self::max_index /
Self::sorted_min_index / Self::sorted_max_index one arity
level down. Read moreSource§fn max_index_of(items: &[Self]) -> Option<usize>
fn max_index_of(items: &[Self]) -> Option<usize>
usize DECLARATION-ORDER INDEX of the declaration-order
N-ARY MAX projection of items — the declaration-order position
of Self::max_of projected through Self::index_of, or
None when items is empty. Read moreSource§fn sorted_min_index_of(items: &[Self]) -> Option<usize>
fn sorted_min_index_of(items: &[Self]) -> Option<usize>
usize LEXICOGRAPHIC-ORDER INDEX of the lex-order N-ARY MIN
projection of items — the lex position of
Self::sorted_min_of projected through
Self::sorted_index_of, or None when items is empty. Read moreSource§fn sorted_max_index_of(items: &[Self]) -> Option<usize>
fn sorted_max_index_of(items: &[Self]) -> Option<usize>
usize LEXICOGRAPHIC-ORDER INDEX of the lex-order N-ARY MAX
projection of items — the lex position of
Self::sorted_max_of projected through
Self::sorted_index_of, or None when items is empty. Read moreSource§fn is_ascending(items: &[Self]) -> bool
fn is_ascending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1]) satisfies items[i].precedes_or_equal(items[i+1])
under Self::ALL’s declaration order, false on the first
consecutive pair that violates non-strict precedence. Folds
Self::precedes_or_equal over items.windows(2) via
Iterator::all — vacuously true on the empty slice AND on
every singleton slice (no adjacent pairs), threading the (0 &&
1)-length identity of Iterator::all on windows(2) through
bool’s conjunctive fold. Read moreSource§fn is_descending(items: &[Self]) -> bool
fn is_descending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1]) satisfies items[i].succeeds_or_equal(items[i+1])
under Self::ALL’s declaration order, false on the first
consecutive pair that violates non-strict succession. The
direction-complement arm of Self::is_ascending on the
(forward, backward) axis of the N-ary monotonicity surface. Read moreSource§fn is_sorted_ascending(items: &[Self]) -> bool
fn is_sorted_ascending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1])
satisfies items[i].sorted_precedes_or_equal(items[i+1]) under
Self::label’s projection into ASCII lexicographic order,
false on the first consecutive pair that violates non-strict
lex-precedence. The lex-ordering peer of Self::is_ascending
on the (declaration, lex) ordering axis of the N-ary
monotonicity surface. Read moreSource§fn is_sorted_descending(items: &[Self]) -> bool
fn is_sorted_descending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1])
satisfies items[i].sorted_succeeds_or_equal(items[i+1]) under
Self::label’s projection into ASCII lexicographic order,
false on the first consecutive pair that violates non-strict
lex-succession. Closes the (ordering × direction) 2×2 =
4-corner N-ary non-strict monotonicity matrix on the closed-set
surface at the (lex-order, descending) corner past the three
prior corners at (declaration, ascending) / (declaration,
descending) / (lex, ascending). Read moreSource§fn is_strictly_ascending(items: &[Self]) -> bool
fn is_strictly_ascending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1]) satisfies items[i].precedes(items[i+1]) under
Self::ALL’s declaration order, false on the first
consecutive pair that violates strict precedence (including
any adjacent equal pair, by irreflexivity of the strict
pairwise-precedence primitive). The strictness-complement arm
of Self::is_ascending on the (strict, non-strict) axis of
the N-ary monotonicity surface. Read moreSource§fn is_strictly_descending(items: &[Self]) -> bool
fn is_strictly_descending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1]) satisfies items[i].succeeds(items[i+1]) under
Self::ALL’s declaration order, false on the first
consecutive pair that violates strict succession (including
any adjacent equal pair). The direction-complement arm of
Self::is_strictly_ascending on the (forward, backward)
axis of the N-ary strict-monotonicity surface AND the
strictness-complement arm of Self::is_descending on the
(strict, non-strict) axis. Read moreSource§fn is_sorted_strictly_ascending(items: &[Self]) -> bool
fn is_sorted_strictly_ascending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1])
satisfies items[i].sorted_precedes(items[i+1]) under
Self::label’s projection into ASCII lexicographic order,
false on the first consecutive pair that violates strict
lex-precedence. The lex-ordering peer of
Self::is_strictly_ascending on the (declaration, lex)
ordering axis of the N-ary strict-monotonicity surface AND
the strictness-complement arm of Self::is_sorted_ascending
on the (strict, non-strict) axis. Read moreSource§fn is_sorted_strictly_descending(items: &[Self]) -> bool
fn is_sorted_strictly_descending(items: &[Self]) -> bool
true iff every consecutive pair (items[i], items[i+1])
satisfies items[i].sorted_succeeds(items[i+1]) under
Self::label’s projection into ASCII lexicographic order,
false on the first consecutive pair that violates strict
lex-succession. Closes the (ordering × direction × strictness)
2×2×2 = 8-corner N-ary monotonicity hypercube on the closed-
set surface at the (lex-order, descending, strict) corner past
the seven prior corners at the four non-strict corners
(105)+(106)+(107)+(108) and the three prior strict corners
(declaration, ascending, strict), (declaration, descending,
strict), (lex, ascending, strict). Read moreSource§fn is_monotonic(items: &[Self]) -> bool
fn is_monotonic(items: &[Self]) -> bool
true iff items is EITHER non-
strictly ascending OR non-strictly descending under
Self::ALL’s declaration order, false when items fails
BOTH directions. The DIRECTION-COLLAPSED opener on the N-ary
monotonicity surface past the exhaustively-closed 8-corner
(arity-N × ordering × direction × strictness) 2×2×2 monotonicity
hypercube (105)+(106)+(107)+(108)+(109)+(110)+(111)+(112) — opens
the (direction-collapsed) axis one dimension over from the
direction-split predicates at the (declaration, non-strict)
corner. Read moreSource§fn is_strictly_monotonic(items: &[Self]) -> bool
fn is_strictly_monotonic(items: &[Self]) -> bool
true iff items is EITHER strictly
ascending OR strictly descending under Self::ALL’s
declaration order, false when items fails BOTH directions
(including any slice with two or more adjacent equal elements,
by irreflexivity of the strict pairwise-precedence primitive
on both direction arms). The strictness-complement arm of
Self::is_monotonic on the (strict, non-strict) axis of the
direction-collapsed N-ary monotonicity surface. Read moreSource§fn is_sorted_monotonic(items: &[Self]) -> bool
fn is_sorted_monotonic(items: &[Self]) -> bool
true iff items is EITHER non-strictly lex-
ascending OR non-strictly lex-descending under Self::label’s
projection into ASCII lexicographic order, false when items
fails BOTH directions. The lex-ordering peer of
Self::is_monotonic on the (declaration, lex) ordering axis
of the direction-collapsed N-ary monotonicity surface. Read moreSource§fn is_sorted_strictly_monotonic(items: &[Self]) -> bool
fn is_sorted_strictly_monotonic(items: &[Self]) -> bool
true iff items is EITHER strictly lex-ascending
OR strictly lex-descending under Self::label’s projection
into ASCII lexicographic order, false when items fails BOTH
directions. Closes the (ordering × strictness) 2×2 = 4-corner
direction-collapsed N-ary monotonicity matrix on the closed-set
surface at the (lex-order, strict) corner past the three prior
corners at (declaration, non-strict) / (declaration, strict) /
(lex, non-strict). Read moreSource§fn is_constant(items: &[Self]) -> bool
fn is_constant(items: &[Self]) -> bool
true iff
items is BOTH non-strictly ascending AND non-strictly descending
under Self::ALL’s declaration order, false otherwise. Since
the substrate’s declaration order is total, the joint condition
holds iff every adjacent pair is EQUAL, i.e. items is a
repetition of ONE variant (possibly zero-arity). The direction-
CONJUNCTION peer of Self::is_monotonic’s direction-DISJUNCTION
on the (∧, ∨) axis of the N-ary monotonicity face — while
Self::is_monotonic widens the direction-split arms through
|| to accept EITHER ordering, this predicate NARROWS them
through && to accept ONLY the constant intersection. Read moreSource§fn is_pairwise_distinct(items: &[Self]) -> bool
fn is_pairwise_distinct(items: &[Self]) -> bool
true iff every ordered pair of positions (i, j) with i < j
in items satisfies items[i] != items[j] (compared via
Self::index_of’s total-ordering discriminator), false on
the first pair of positions whose variants coincide. The
DISTINCTNESS-axis opener on the closed-set surface — dual to
Self::is_constant on the (constant, distinct) axis of the
N-ary element-equivalence face — while Self::is_constant
narrows to slices where every ordered pair AGREES, this
predicate widens to slices where every ordered pair DIFFERS. Read moreSource§fn count_distinct(items: &[Self]) -> usize
fn count_distinct(items: &[Self]) -> usize
usize cardinality of the SET of variant identities that
occur in items, computed as the count of positions whose
variant does not appear at any strictly-lesser position (a
“first-occurrence” sweep keyed on Self::index_of). The
USIZE-RETURN opener on the (return-shape) column of the
N-ary element-equivalence surface past the pre-existing
bool-return endpoints Self::is_constant (all elements
AGREE) and Self::is_pairwise_distinct (all elements
DIFFER) — while both bool-return endpoints answer a YES/NO
question about the extremes of the equivalence-partition
axis, this projection reports the EXACT distinctness
cardinality of the multiset the slice underlies, folding
both endpoints into two special values of ONE numerical
invariant. Not a fresh substrate primitive on the index axis
— the count emerges from the Self::index_of bijection
applied position-by-position with a strictly-lesser-position
dedup sweep, so the return value is a typed CONSEQUENCE of
the substrate’s total-ordering discriminator. Read moreSource§fn is_covering(items: &[Self]) -> bool
fn is_covering(items: &[Self]) -> bool
true iff every variant of Self::ALL occurs at
least once in items. The BOOL-RETURN opener on the (covering)
axis of the equivalence-partition surface, positioned as a typed
CONSEQUENCE of the just-lifted USIZE-return Self::count_distinct
projection reaching the substrate-carried upper bound
Self::CARDINALITY. The predicate answers YES/NO to “does this
slice HIT every variant?” — dual to Self::is_pairwise_distinct
(which answers YES/NO to “does this slice REPEAT any variant?”)
on the same equivalence-partition surface, and orthogonal to
Self::is_constant (which answers YES/NO to “do all positions
SHARE one variant?”). Not a fresh substrate primitive on the
index axis — the predicate emerges from a single equality check
on the just-lifted usize-return count against the trait-level
Self::CARDINALITY constant. Read moreSource§fn is_permutation_of_all(items: &[Self]) -> bool
fn is_permutation_of_all(items: &[Self]) -> bool
Source§fn count_missing(items: &[Self]) -> usize
fn count_missing(items: &[Self]) -> usize
usize cardinality of the SET of variants of Self::ALL that
do NOT occur in items, computed as the substrate-carried
Self::CARDINALITY constant minus the just-lifted usize-return
Self::count_distinct projection. The USIZE-RETURN opener on
the (absent) column of the (present, absent) partition-arm axis
of the equivalence-partition surface, positioned as the direct
dual of Self::count_distinct one column of the (partition-
arm) axis over — while Self::count_distinct reports “how
many variants does the slice HIT?”, this projection reports
“how many variants does the slice MISS?”, folding the ambient
set’s partition into hit and miss cardinalities. Not a fresh
substrate primitive on the index axis — the count emerges from
one usize-subtraction of the just-lifted usize-return
Self::count_distinct projection from the trait-level
Self::CARDINALITY constant. Read moreSource§fn is_missing_any(items: &[Self]) -> bool
fn is_missing_any(items: &[Self]) -> bool
true iff AT LEAST ONE variant of Self::ALL does NOT occur
in items, computed as the just-lifted usize-return
Self::count_missing projection strictly exceeding zero. The
BOOL-RETURN closer on the (absent) arm of the (present, absent)
× (bool, usize) 2×2 = 4-corner partition-arm × return-shape
face on the equivalence-partition surface, positioned as the
direct DE MORGAN dual of Self::is_covering one column of
the (partition-arm) axis over — while Self::is_covering
reports “does the slice HIT every variant?”, this projection
reports “does the slice MISS any variant?”, folding the
ambient set’s partition arms through the negation into the
bool-return absent-arm. Not a fresh substrate primitive on the
index axis — the predicate emerges from one comparison of the
just-lifted Self::count_missing projection against zero,
equivalently one ! on the just-lifted Self::is_covering
predicate. Read moreSource§fn count_occurrences_of(target: Self, items: &[Self]) -> usize
fn count_occurrences_of(target: Self, items: &[Self]) -> usize
usize cardinality of the SET of positions of
items whose variant identity coincides with target, computed
as a per-position Self::index_of equality-filter through
.count(). The PER-TARGET USIZE-RETURN opener on the
(per-target × usize) MULTIPLICITY column of the equivalence-
partition surface, positioned as the direct PER-TARGET
DECOMPOSITION of the just-lifted N-ary set-level
Self::count_distinct projection — while
Self::count_distinct reports “how many DISTINCT variants
does the slice hit?” (a single set-level usize), this
projection reports “how many times does THIS variant appear?”
(a per-target usize that varies with target). Not a fresh
substrate primitive on the index axis — the count emerges from
one composition of the substrate’s total-ordering discriminator
Self::index_of pinned as a bijection into
[0, T::CARDINALITY) by clause (16) with the standard-library
filter-through-count combinator. Read moreSource§fn occurs_in(target: Self, items: &[Self]) -> bool
fn occurs_in(target: Self, items: &[Self]) -> bool
true iff AT LEAST ONE position of items carries
the same variant identity as target, computed as the just-
lifted usize-return Self::count_occurrences_of per-target
multiplicity projection strictly exceeding zero. The PER-TARGET
BOOL-RETURN opener on the (per-target × bool) MEMBERSHIP column
of the equivalence-partition surface, positioned as the direct
PER-TARGET DECOMPOSITION of the just-lifted N-ary set-level
Self::is_covering present-arm predicate one column of the
(per-target, set-level) arity axis over — while
Self::is_covering reports “does the slice HIT every
variant?” (a single set-level bool), this projection reports
“does the slice HIT THIS variant?” (a per-target bool that
varies with target). The (per-target, set-level) × (bool,
usize) 2×2 = 4-corner (arity × return-shape) face on the
equivalence-partition surface now closes the bool per-target
column at the (bool, per-target) corner peer to the (usize,
per-target) corner Self::count_occurrences_of opened. Read moreSource§fn first_occurrence_of(target: Self, items: &[Self]) -> Option<usize>
fn first_occurrence_of(target: Self, items: &[Self]) -> Option<usize>
Some(i) for the SMALLEST slice index i at which items[i]
carries the same variant identity as target, or None if
target does not appear. The PER-TARGET Option<usize>-RETURN
opener on the (per-target × Option<usize>) HEAD-POSITION column
of the equivalence-partition surface, positioned as the direct
POSITION-VALUE lift of the just-lifted bool-return
Self::occurs_in one return-shape axis over — while
Self::occurs_in reports “does the slice HIT this variant?”
(a per-target bool), this projection reports “at WHICH position
does the slice FIRST hit this variant?” (a per-target
Option<usize> whose Some arm carries the head-position and
whose None arm collapses onto Self::occurs_in’s false
arm). Read moreSource§fn last_occurrence_of(target: Self, items: &[Self]) -> Option<usize>
fn last_occurrence_of(target: Self, items: &[Self]) -> Option<usize>
Some(i) for the LARGEST slice index i at which items[i]
carries the same variant identity as target, or None if
target does not appear. Sibling to
Self::first_occurrence_of one endpoint-direction axis over
on the (per-target × Option<usize> × endpoint-direction) 2-
corner face: Self::first_occurrence_of returns the smallest
matching slice index; this method returns the largest. Read moreSource§fn all_occurrences_of(target: Self, items: &[Self]) -> Vec<usize>
fn all_occurrences_of(target: Self, items: &[Self]) -> Vec<usize>
Vec<usize> of EVERY slice index at which items[i]
carries the same variant identity as target, in strictly
ascending slice-order. The PER-TARGET Vec<usize>-RETURN
opener on the (per-target × Vec<usize>) EVERY-POSITION column
of the equivalence-partition surface, positioned as the direct
VEC-LIFT of the just-lifted endpoint-anchor pair
Self::first_occurrence_of + Self::last_occurrence_of
one return-shape axis over — while those two projections report
the SMALLEST and LARGEST matching slice indices (a per-target
Option<usize> singleton at either endpoint of the matching
index set), THIS projection reports the ENTIRE matching index
set (a per-target Vec<usize> of every matching slice index).
The (per-target × return-shape) row on the equivalence-
partition surface now carries five typed corners:
Self::count_occurrences_of (usize; multiplicity),
Self::occurs_in (bool; membership),
Self::first_occurrence_of (Option<usize>; head-position),
Self::last_occurrence_of (Option<usize>; tail-position),
and THIS projection (Vec<usize>; every-position). Read moreSource§fn occurrence_endpoints_of(
target: Self,
items: &[Self],
) -> Option<(usize, usize)>
fn occurrence_endpoints_of( target: Self, items: &[Self], ) -> Option<(usize, usize)>
Some((first, last)) for the SMALLEST + LARGEST slice indices
at which items carries the same variant identity as target,
or None if target does not appear. The PER-TARGET
Option<(usize, usize)>-RETURN opener on the (per-target ×
Option<(usize, usize)>) ENDPOINT-PAIR column of the
equivalence-partition surface, positioned as the direct PAIR-
PACKAGED lift of the just-lifted
Self::first_occurrence_of + Self::last_occurrence_of
endpoint-anchor pair — while
the endpoint-anchor pair reports the head- and tail-position
across TWO separate Option<usize> returns, this projection
packages both endpoints into ONE atomic Option<(usize, usize)>
return via Option::zip on the two endpoint-anchor primitives.
Sibling posture to Self::variant_count_range one arity axis
over: the set-level projection returns (usize, usize) =
(min_variant_count, max_variant_count) of the histogram bars;
the per-target projection returns Option<(usize, usize)> =
the (head-position, tail-position) endpoint pair of a target’s
slice occurrences. The (per-target × return-shape) row on the
equivalence-partition surface now closes the pair-return
column at the (Option<(usize, usize)>, per-target) corner
peer to the (Vec<usize>, per-target) corner
Self::all_occurrences_of just opened. Read moreSource§fn occurrence_span_of(target: Self, items: &[Self]) -> Option<usize>
fn occurrence_span_of(target: Self, items: &[Self]) -> Option<usize>
Option<usize> slot-difference reduction of
the Self::occurrence_endpoints_of endpoint-pair corner
(Some(l - f) on the Some((f, l)) arm, None when the
target does not appear). The PER-TARGET Option<usize>-RETURN
SCALAR-DIFFERENCE REDUCTION opener on the (per-target ×
Option<usize> scalar-difference) column of the equivalence-
partition surface, positioned as the direct SCALAR-DIFFERENCE
projection of the just-lifted Self::occurrence_endpoints_of
pair-return corner. Sibling posture to
Self::variant_count_span one arity axis over: the set-level
projection returns usize = max_variant_count - min_variant_count = the scalar-difference reduction of the
(min-bar, max-bar) direction pair via Self::variant_count_range;
the per-target projection returns Option<usize> = l - f =
the scalar-difference reduction of the (head, tail) endpoint
pair via Self::occurrence_endpoints_of. Both share the same
abstract shape “reduce a pair-return corner through slot-
subtraction to a scalar” but on different arities of the same
substrate — the set-level column reduces the (min-bar, max-bar)
direction pair; the per-target column reduces the (head, tail)
endpoint pair. The (per-target × return-shape) row on the
equivalence-partition surface now closes the Option<usize>
scalar-difference column at the (Option<usize>, per-target,
scalar-difference) corner peer to the (Option<(usize, usize)>,
per-target, pair) corner Self::occurrence_endpoints_of
just opened. Read moreSource§fn is_unique_occurrence_of(target: Self, items: &[Self]) -> bool
fn is_unique_occurrence_of(target: Self, items: &[Self]) -> bool
bool per-target UNIQUENESS test whose value
coincides with T::count_occurrences_of(target, items) == 1,
i.e. true iff the target appears EXACTLY ONCE in items.
The PER-TARGET bool-RETURN MULTIPLICITY-BAND CLOSER on the
(per-target × bool) column of the equivalence-partition surface,
positioned as the direct MULTIPLICITY-BAND projection of the
just-lifted usize-return Self::count_occurrences_of per-
target multiplicity primitive, one MULTIPLICITY-BAND axis over
from the (per-target × bool) MULTIPLICITY-POSITIVE corner
Self::occurs_in: while Self::occurs_in reports “does
the slice HIT this variant at least ONCE?” (multiplicity-band
> 0), this projection reports “does the slice HIT this
variant EXACTLY ONCE?” (multiplicity-band == 1). The (per-
target × bool × multiplicity-band) 2-corner face on the
equivalence-partition surface now closes at the (bool, per-
target, == 1) corner peer to the (bool, per-target, > 0)
corner Self::occurs_in opened. Read moreSource§fn is_repeated_occurrence_of(target: Self, items: &[Self]) -> bool
fn is_repeated_occurrence_of(target: Self, items: &[Self]) -> bool
bool per-target REPETITION test whose value
coincides with T::count_occurrences_of(target, items) >= 2,
i.e. true iff the target appears AT LEAST TWICE in items.
The PER-TARGET bool-RETURN MULTIPLICITY-BAND CLOSER on the
(per-target × bool) column of the equivalence-partition surface,
positioned as the direct MULTIPLICITY-BAND projection of the
Self::count_occurrences_of per-target multiplicity primitive
one MULTIPLICITY-BAND axis over from BOTH the (per-target × bool)
MULTIPLICITY-POSITIVE corner Self::occurs_in (mult > 0)
AND the (per-target × bool) MULTIPLICITY-EQUALS-ONE corner
Self::is_unique_occurrence_of (mult == 1). The three
bands (== 0, == 1, >= 2) partition the per-target
multiplicity axis exhaustively into three disjoint arms,
exposed on the trait through the disjoint predicate triple
(!occurs_in, is_unique_occurrence_of,
is_repeated_occurrence_of) that closes the (per-target × bool
× multiplicity-band) 3-corner face on the equivalence-partition
surface — every position on the per-target multiplicity axis
binds to exactly ONE of the three typed predicates. Read moreSource§fn is_saturated_by(target: Self, items: &[Self]) -> bool
fn is_saturated_by(target: Self, items: &[Self]) -> bool
true iff every position of items sits at the
target variant, computed as the strict-equality test of the
per-target multiplicity primitive Self::count_occurrences_of
against the slice arity items.len(). The PER-TARGET × bool ×
per-position-universal-quantifier corner OPENING the (per-target
× bool × per-position-quantifier) 2-corner face on the
equivalence-partition surface at the ∀-arm peer to the pre-
existing (per-target × bool × per-position-EXISTENTIAL-quantifier)
Self::occurs_in ∃-arm one QUANTIFIER-axis over — the ∃/∀
duality on the PER-POSITION quantifier axis at the SAME per-
target arity. Distinct from the (per-target × bool ×
multiplicity-band) trichotomy corners Self::occurs_in (mult
> 0) / Self::is_unique_occurrence_of (mult == 1) /
Self::is_repeated_occurrence_of (mult >= 2) which sit on
the multiplicity-band axis, while this predicate sits on the
slice-arity-relative saturation axis (multiplicity == items.len()). Read moreSource§fn variant_counts(items: &[Self]) -> Vec<usize>
fn variant_counts(items: &[Self]) -> Vec<usize>
Vec<usize> DECLARATION-ORDER histogram over
Self::ALL whose slot i reports the multiplicity of
T::ALL[i] in items. The Vec<usize> per-slot histogram
opener on the (per-target × Vec) column of the equivalence-
partition surface, positioned as the concrete AGGREGATION
behind the just-lifted usize-return Self::count_occurrences_of
per-target multiplicity primitive (which reports the
multiplicity of ONE target) and the Vec-return
Self::present_variants present-witness projection (which
reports the STRICTLY-POSITIVE arm of the same histogram as a
typed variant witness). The (per-target, per-slot) × (usize,
Vec) 2×2 = 4-corner (arity × return-shape) face on the
equivalence-partition surface now closes the Vec<usize> per-
slot column at the (Vecusize, per-target) corner Self::count_occurrences_of
opened. Read moreSource§fn sorted_variant_counts(items: &[Self]) -> Vec<usize>
fn sorted_variant_counts(items: &[Self]) -> Vec<usize>
Vec<usize> LEX-ORDER histogram
over Self::sorted_variants whose slot i reports the
multiplicity of T::sorted_variants()[i] in items. The
LEX-ORDER peer of Self::variant_counts on the (declaration,
lex) ordering axis of the (per-slot × VecSelf::variant_counts opened. The
(per-slot × VecSource§fn max_variant_count(items: &[Self]) -> usize
fn max_variant_count(items: &[Self]) -> usize
usize MAX-BAR of Self::variant_counts, reporting the
largest per-variant occurrence count across Self::ALL, or
0 when items is empty. The SCALAR-STATISTIC opener on the
(set-level × usize × statistical-aggregate) column of the
equivalence-partition surface — the FIRST typed set-level scalar
aggregate to reduce the Self::variant_counts Vec<usize>
histogram to a single usize bar-height statistic past the
pre-existing (set-level × usize × cardinality) column of
Self::count_distinct + Self::count_missing (which count
slots of the histogram — the count of non-zero bars and the
count of zero bars — rather than the bars’ magnitudes). Read moreSource§fn min_variant_count(items: &[Self]) -> usize
fn min_variant_count(items: &[Self]) -> usize
usize MIN-BAR of Self::variant_counts,
reporting the smallest per-variant occurrence count across
Self::ALL, or 0 when items is empty. The SCALAR-STATISTIC
closer on the (min-bar, max-bar) direction axis of the
(set-level × usize × statistical-aggregate) column of the
equivalence-partition surface, positioned as the DIRECT
(min-bar) PEER to the just-lifted (max-bar) corner
Self::max_variant_count. The (min-bar, max-bar) direction
axis of the statistical-aggregate column now closes at both
corners: the max-bar reports the LARGEST per-variant occurrence
count (the modal multiplicity), and this min-bar reports the
SMALLEST per-variant occurrence count (the least-common
multiplicity). Read moreSource§fn variant_count_range(items: &[Self]) -> (usize, usize)
fn variant_count_range(items: &[Self]) -> (usize, usize)
(usize, usize) PAIR of the histogram’s (min-bar, max-bar)
endpoints projected onto the trait surface as ONE call. The
PAIR-RETURN endpoint-anchor opener on the (set-level ×
statistical-aggregate) column of the equivalence-partition
surface, positioned as the direct TUPLE-RETURN peer to the
two just-closed scalar-return direction corners
Self::min_variant_count + Self::max_variant_count one
return-shape axis over. The (set-level × statistical-aggregate)
× (usize-scalar, (usize, usize)-pair) 2-corner return-shape
face on the equivalence-partition surface now opens the pair-
return endpoint-anchor column past the (min-bar) + (max-bar)
scalar corners. Read moreSource§fn is_uniform(items: &[Self]) -> bool
fn is_uniform(items: &[Self]) -> bool
true iff every per-variant occurrence count in items
coincides at ONE scalar bar-height, computed as the just-
lifted pair-return Self::variant_count_range projection’s
two direction endpoints agreeing byte-for-byte. The BOOL-
RETURN UNIFORMITY closer on the (set-level × statistical-
aggregate) row of the equivalence-partition surface,
positioned as the direct SCALAR-REDUCTION of the just-opened
pair-return endpoint-anchor corner
Self::variant_count_range through the (slot-0 == slot-1)
tuple-projection equality. The (set-level × statistical-
aggregate) × (usize-scalar, (usize, usize)-pair,
bool-scalar) 3-corner return-shape face on the equivalence-
partition surface now closes the bool-return uniformity column
past the two scalar direction corners
Self::min_variant_count + Self::max_variant_count and
past the pair-return endpoint-anchor corner
Self::variant_count_range, packaging the histogram’s
(min-bar == max-bar) degeneracy-check as ONE bool. Read moreSource§fn variant_count_span(items: &[Self]) -> usize
fn variant_count_span(items: &[Self]) -> usize
usize NON-NEGATIVE scalar-difference of the just-lifted
pair-return Self::variant_count_range projection’s two
direction endpoints, computed as max_bar - min_bar on the
(max-bar, min-bar) pair. The SCALAR-DIFFERENCE range-width
opener on the (set-level × statistical-aggregate) row of the
equivalence-partition surface, positioned as the second
SCALAR REDUCTION of the just-opened pair-return endpoint-
anchor corner Self::variant_count_range through the
(slot-1 - slot-0) tuple-projection SATURATED DIFFERENCE
(the pair-return corner pins slot-0 <= slot-1 by clause
(102)’s direction-axis-order arm, so the difference is
non-negative and no saturation ever fires). Peer posture to
Self::is_uniform one return-shape axis over: the bool-
return uniformity corner reduces the pair through
slot-EQUALITY (min == max), yielding a bare bool; this
usize-return span corner reduces the SAME pair through
slot-SUBTRACTION (max - min), yielding a bare usize
range-width. The (set-level × statistical-aggregate) ×
(usize-scalar-direction, (usize, usize)-pair,
bool-scalar, usize-scalar-difference) 4-corner return-
shape face on the equivalence-partition surface now opens
its FOURTH corner as the direct SCALAR-DIFFERENCE reduction
of the pair-return corner past the two direction corners,
the pair-return corner, and the bool-return uniformity
corner. Read moreSource§fn modal_variant(items: &[Self]) -> Option<Self>
fn modal_variant(items: &[Self]) -> Option<Self>
Option<Self> DECLARATION-ORDER-FIRST ARGMAX over the
Self::variant_counts histogram, reporting the FIRST variant
of Self::ALL (walked in declaration order) whose per-target
count equals Self::max_variant_count, or None when items
is empty. The ARGMAX-VARIANT opener on the (set-level ×
Option<Self> × statistical-aggregate) column of the
equivalence-partition surface, positioned as the FIRST typed
Option<Self>-return aggregate past the (set-level × usize ×
statistical-aggregate) direction column (Self::max_variant_count,
Self::min_variant_count), the (set-level × (usize, usize) ×
pair-endpoint) column (Self::variant_count_range), the (set-
level × bool × uniformity) column (Self::is_uniform), and
the (set-level × usize × scalar-difference) column
(Self::variant_count_span). Where the scalar-return corners
project the histogram’s MAGNITUDES (max-bar, min-bar, range,
span) or the FLATNESS witness (uniformity), this projection
promotes the ARGUMENT — the substrate variant achieving the
max-bar — from an inline T::ALL.iter().find(|&&v| T::count_occurrences_of(v, items) == T::max_variant_count(items)) .copied() sweep at every prospective downstream “which variant
is the histogram’s peak?” site to a typed Option<Self>-return
primitive on the trait. Not a fresh substrate primitive on the
index axis — the projection emerges from ONE
T::ALL.iter().find(|&&v| ...) sweep whose predicate binds
Self::count_occurrences_of against the just-lifted
Self::max_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to None past the (max == 0,
every-count == 0) degenerate arm where an ungauded sweep would
silently return Some(T::ALL[0]). Read moreSource§fn sorted_modal_variant(items: &[Self]) -> Option<Self>
fn sorted_modal_variant(items: &[Self]) -> Option<Self>
Option<Self> LEX-ORDER-FIRST ARGMAX over the
Self::variant_counts histogram, reporting the FIRST variant
of Self::sorted_variants (walked in lex order) whose per-
target count equals Self::max_variant_count, or None when
items is empty. The LEX-ORDER peer of Self::modal_variant
on the (declaration, lex) ordering axis of the (set-level ×
Option<Self> × statistical-aggregate) column — closes the lex
arm past the declaration arm the sibling Self::modal_variant
opened. Where Self::modal_variant walks Self::ALL in
DECLARATION order and commits at the first tied argmax, this
projection walks Self::sorted_variants in LEX order and
commits at the first tied argmax under the ASCII-sort_unstable
discriminator. The two projections AGREE byte-for-byte on every
slice whose argmax is UNIQUE (a single variant achieves the
modal multiplicity) AND on every slice whose argmax ties SIT
ENTIRELY within the (declaration-order-first == lex-order-first)
tie-break agreement window; they BIFURCATE at the smallest slice
whose argmax ties spread across a (T::first() != T::sorted_first()) declaration/lex divergence. Not a fresh
substrate primitive on the index axis — the projection emerges
from ONE sorted_variants().into_iter().find(|&v| ...) sweep
whose predicate binds Self::count_occurrences_of against the
just-lifted Self::max_variant_count scalar, guarded by an
empty-slice short-circuit that maps &[] to None past the
(max == 0, every-count == 0) degenerate arm where an unguarded
sweep would silently return Some(T::sorted_first()). Read moreSource§fn antimodal_variant(items: &[Self]) -> Option<Self>
fn antimodal_variant(items: &[Self]) -> Option<Self>
Option<Self> DECLARATION-ORDER-FIRST ARGMIN over the
Self::variant_counts histogram, reporting the FIRST variant
of Self::ALL (walked in declaration order) whose per-target
count equals Self::min_variant_count, or None when items
is empty. The DIRECTION-AXIS peer of Self::modal_variant on
the (max-bar, min-bar) direction axis of the (set-level ×
Option<Self> × statistical-aggregate) column — opens the
argmin arm past the argmax arm the sibling Self::modal_variant
closed on the declaration-order corner. Where
Self::modal_variant finds the variant achieving
Self::max_variant_count, this projection finds the variant
achieving Self::min_variant_count. On any slice with a
missing variant (equivalently, Self::is_missing_any holds,
equivalently, min == 0), the antimodal points at a MISSING
witness; on a covering slice (min ≥ 1), the antimodal points at
the least-common PRESENT variant. Not a fresh substrate
primitive on the index axis — the projection emerges from ONE
T::ALL.iter().copied().find(|&v| ...) sweep whose predicate
binds Self::count_occurrences_of against the just-lifted
Self::min_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to None past the (min == 0,
every-count == 0) degenerate arm where an unguarded sweep would
silently return Some(T::first()). Read moreSource§fn sorted_antimodal_variant(items: &[Self]) -> Option<Self>
fn sorted_antimodal_variant(items: &[Self]) -> Option<Self>
Option<Self> LEX-ORDER-FIRST ARGMIN over the
Self::variant_counts histogram, reporting the FIRST variant
of Self::sorted_variants (walked in lex order) whose per-target
count equals Self::min_variant_count, or None when items
is empty. The ORDERING-AXIS peer of Self::antimodal_variant on
the (declaration, lex) ordering axis of the (set-level ×
Option<Self> × statistical-aggregate × direction) column — CLOSES
the (direction × ordering) 4-corner face at its final (argmin, lex)
corner past the argmax arm the sibling Self::sorted_modal_variant
closed one direction-axis over. Where Self::antimodal_variant
finds the DECLARATION-ORDER-FIRST variant achieving
Self::min_variant_count, this projection finds the
LEX-ORDER-FIRST variant achieving Self::min_variant_count. On
any slice with a missing variant (equivalently,
Self::is_missing_any holds, equivalently, min == 0), the
sorted-antimodal points at the lex-order-first MISSING witness; on
a covering slice (min ≥ 1), the sorted-antimodal points at the
lex-order-first least-common PRESENT variant. Not a fresh substrate
primitive on the index axis — the projection emerges from ONE
T::sorted_variants().into_iter().find(|&v| ...) sweep whose
predicate binds Self::count_occurrences_of against
Self::min_variant_count, guarded by an empty-slice
short-circuit that maps &[] to None past the (min == 0,
every-count == 0) degenerate arm where an unguarded sweep would
silently return Some(T::sorted_first()). Read moreSource§fn modal_variants(items: &[Self]) -> Vec<Self>
fn modal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER witness-collection of EVERY
variant of Self::ALL whose per-target count equals
Self::max_variant_count, preserving Self::ALL’s
declaration order and returning the empty vector when items
is empty. The Vec-RETURN opener on the (set-level ×
Vec<Self> × statistical-aggregate × direction × argmax)
corner peer to the (set-level × Option<Self> × statistical-
aggregate × direction × argmax) Self::modal_variant corner
one RETURN-SHAPE axis over — while Self::modal_variant
reports the FIRST tied argmax variant (a single-witness
commit), this projection reports EVERY tied argmax variant (a
COMPLETE witness-collection, no tie-break choice). The (set-
level × {Option<Self>, Vec<Self>} × statistical-aggregate ×
argmax × declaration-order) 2-corner (return-shape) row on the
equivalence-partition surface now closes the Vec<Self> per-
direction column past the Option<Self> first-witness column
Self::modal_variant closed. Read moreSource§fn sorted_modal_variants(items: &[Self]) -> Vec<Self>
fn sorted_modal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER witness-collection of EVERY variant
of Self::sorted_variants whose per-target count equals
Self::max_variant_count, preserving
Self::sorted_variants’s canonical ASCII-lex order and
returning the empty vector when items is empty. The LEX-ORDER
peer of Self::modal_variants one ORDERING axis over,
CLOSING the (set-level × Vec<Self> × statistical-aggregate ×
argmax × ordering) 2-corner face at its lex-arm past the
declaration-arm the sibling Self::modal_variants opened.
One RETURN-SHAPE axis over from Self::sorted_modal_variant
(Option<Self> first-witness under the lex tie-break): while
Self::sorted_modal_variant reports the FIRST tied argmax
variant walked in lex order, this projection reports EVERY
tied argmax variant walked in lex order — a COMPLETE witness-
collection with a canonical alphabetic display order, no tie-
break choice. Not a fresh substrate primitive on the index
axis — the projection emerges from ONE
T::sorted_variants().into_iter().filter(|&v| T::count_occurrences_of(v, items) == T::max_variant_count(items)) .collect() sweep whose predicate binds
Self::count_occurrences_of against the just-lifted
Self::max_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to Vec::new() past the (max ==
0, every-count == 0) degenerate arm where an unguarded sweep
would silently return T::sorted_variants(). Read moreSource§fn antimodal_variants(items: &[Self]) -> Vec<Self>
fn antimodal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER witness-collection of EVERY
variant of Self::ALL whose per-target count equals
Self::min_variant_count, preserving Self::ALL’s canonical
declaration order and returning the empty vector when items is
empty. The DIRECTION-ANCHOR ARGMIN peer of Self::modal_variants
one DIRECTION axis over, OPENING the argmin arm of the (set-level
× Vec<Self> × statistical-aggregate × direction) column past
the argmax arm the sibling Self::modal_variants opened. One
RETURN-SHAPE axis over from Self::antimodal_variant
(Option<Self> first-witness under the declaration tie-break):
while Self::antimodal_variant reports the FIRST tied argmin
variant walked in declaration order, this projection reports
EVERY tied argmin variant walked in declaration order — a
COMPLETE witness-collection with the canonical authoring order,
no tie-break choice. Not a fresh substrate primitive on the
index axis — the projection emerges from ONE
T::ALL.iter().copied().filter(|&v| T::count_occurrences_of(v, items) == T::min_variant_count(items)) .collect() sweep whose predicate binds
Self::count_occurrences_of against the just-lifted
Self::min_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to Vec::new() past the (min == 0,
every-count == 0) degenerate arm where an unguarded sweep would
silently return T::ALL.to_vec(). Read moreSource§fn sorted_antimodal_variants(items: &[Self]) -> Vec<Self>
fn sorted_antimodal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER witness-collection of EVERY variant of
Self::sorted_variants whose per-target count equals
Self::min_variant_count, preserving Self::sorted_variants’s
canonical ASCII-lex order and returning the empty vector when
items is empty. The FINAL corner CLOSING the (return-shape ×
direction × ordering) 2×2×2 = 8-corner cube at its (VecSelf::antimodal_variants
one ORDERING axis over on the argmin arm — peer to
Self::sorted_modal_variants one DIRECTION axis over on the
lex-ordering arm. One RETURN-SHAPE axis over from
Self::sorted_antimodal_variant (Option<Self> first-witness
under the lex tie-break): while Self::sorted_antimodal_variant
reports the FIRST tied argmin variant walked in lex order, this
projection reports EVERY tied argmin variant walked in lex order —
a COMPLETE witness-collection with a canonical alphabetic display
order, no tie-break choice. Not a fresh substrate primitive on
the index axis — the projection emerges from ONE
T::sorted_variants().into_iter().filter(|&v| T::count_occurrences_of(v, items) == T::min_variant_count(items)) .collect() sweep whose predicate binds
Self::count_occurrences_of against the just-lifted
Self::min_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to Vec::new() past the (min == 0,
every-count == 0) degenerate arm where an unguarded sweep would
silently return T::sorted_variants(). Read moreSource§fn count_modal_variants(items: &[Self]) -> usize
fn count_modal_variants(items: &[Self]) -> usize
usize SET-LEVEL count of
variants of Self::ALL whose per-target multiplicity in items
equals Self::max_variant_count, computed as the filter-count
reduction over Self::ALL of the (count(v) == max)
direction-anchor predicate. The USIZE-RETURN OPENER on the (set-
level × usize × statistical-aggregate × direction × argmax)
cardinality-count corner peer to the (set-level × Vec<Self> ×
statistical-aggregate × direction × argmax) Self::modal_variants
complete-witness corner one RETURN-SHAPE axis over on the modal-
aggregation matrix (Vec<Self> witness → usize cardinality via
the trivial .len() sharpening) AND peer to the (set-level ×
usize × multiplicity-band == 1) Self::count_unique_variants
and (set-level × usize × multiplicity-band >= 2)
Self::count_repeating_variants and (set-level × usize ×
multiplicity-band == 0) Self::count_missing cardinality-
count corners one AGGREGATION-KIND axis over on the (set-level ×
usize) row of the equivalence-partition surface (multiplicity-
band → direction-anchor aggregation-kind bifurcation). Not a fresh
substrate primitive on the index axis — the count emerges from
one is_empty()-guarded filter-count reduction over Self::ALL
of the (count(v) == max) predicate against the just-lifted
Self::max_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to 0 past the (max == 0, every-
count == 0) degenerate arm where an unguarded sweep would silently
return Self::CARDINALITY (every variant satisfies the vacuous
0 == 0 predicate) — equivalently, the length of the just-lifted
Self::modal_variants complete-witness Vec. Read moreSource§fn count_antimodal_variants(items: &[Self]) -> usize
fn count_antimodal_variants(items: &[Self]) -> usize
usize SET-LEVEL
count of variants of Self::ALL whose per-target multiplicity
in items equals Self::min_variant_count, computed as the
filter-count reduction over Self::ALL of the
(count(v) == min) direction-anchor predicate. The USIZE-RETURN
CLOSER on the (set-level × usize × statistical-aggregate ×
direction × argmin) cardinality-count corner CLOSING the (set-
level × usize × statistical-aggregate × direction) 2-corner
cardinality-count face peer to the (set-level × usize ×
statistical-aggregate × direction × argmax)
Self::count_modal_variants cardinality-count corner one
DIRECTION axis over on the modal-aggregation matrix, AND peer to
the (set-level × Vec<Self> × statistical-aggregate × direction ×
argmin) Self::antimodal_variants complete-witness corner one
RETURN-SHAPE axis over on the same direction-anchor arm
(Vec<Self> witness → usize cardinality via the trivial
.len() sharpening). Not a fresh substrate primitive on the
index axis — the count emerges from one is_empty()-guarded
filter-count reduction over Self::ALL of the
(count(v) == min) predicate against the just-lifted
Self::min_variant_count scalar, guarded by an empty-slice
short-circuit that maps &[] to 0 past the (min == 0, every-
count == 0) degenerate arm where an unguarded sweep would
silently return Self::CARDINALITY (every variant satisfies
the vacuous 0 == 0 predicate) — equivalently, the length of the
just-lifted Self::antimodal_variants complete-witness Vec. Read moreSource§fn is_modal_variant_of(target: Self, items: &[Self]) -> bool
fn is_modal_variant_of(target: Self, items: &[Self]) -> bool
true iff target’s per-target multiplicity in items
coincides with Self::max_variant_count AND items is non-empty,
computed as the conjunction of the non-emptiness guard with the
strict-equality test of Self::count_occurrences_of against
Self::max_variant_count. The BOOL-RETURN opener on the (per-
target × bool × statistical-aggregate × direction × argmax) corner,
positioned as the direct SET-LEVEL-EXISTENTIAL-LIFT INVERSE — the
per-target arity peer — of the (set-level × usize × statistical-
aggregate × direction × argmax) cardinality-count corner
Self::count_modal_variants one ARITY axis over (set-level ×
usize → per-target × bool), AND the STATISTICAL-AGGREGATE peer
of the pre-existing (per-target × bool × multiplicity-band == 1)
Self::is_unique_occurrence_of one PREDICATE-KIND axis over
(multiplicity-band → statistical-aggregate) on the same per-target
bool row of the equivalence-partition surface. Not a fresh
substrate primitive on the index axis — the predicate emerges from
one non-emptiness guard conjoined with one strict-equality test of
Self::count_occurrences_of against Self::max_variant_count,
equivalently the [Vec::contains] membership of the target in the
just-lifted Self::modal_variants argmax witness-collection. Read moreSource§fn is_antimodal_variant_of(target: Self, items: &[Self]) -> bool
fn is_antimodal_variant_of(target: Self, items: &[Self]) -> bool
true iff target’s per-target multiplicity in
items coincides with Self::min_variant_count AND items is
non-empty, computed as the conjunction of the non-emptiness guard
with the strict-equality test of Self::count_occurrences_of
against Self::min_variant_count. The BOOL-RETURN CLOSER on the
(per-target × bool × statistical-aggregate × direction × argmin)
corner CLOSING the (per-target × bool × statistical-aggregate ×
direction) 2-corner face at its argmin arm past the argmax corner
Self::is_modal_variant_of one DIRECTION axis over, AND the
direct SET-LEVEL-EXISTENTIAL-LIFT INVERSE — the per-target arity
peer — of the (set-level × usize × statistical-aggregate ×
direction × argmin) cardinality-count corner
Self::count_antimodal_variants one ARITY axis over (set-level ×
usize → per-target × bool). Not a fresh substrate primitive on
the index axis — the predicate emerges from one non-emptiness
guard conjoined with one strict-equality test of
Self::count_occurrences_of against Self::min_variant_count,
equivalently the [Vec::contains] membership of the target in the
just-lifted Self::antimodal_variants argmin witness-collection. Read moreSource§fn has_unique_mode(items: &[Self]) -> bool
fn has_unique_mode(items: &[Self]) -> bool
true iff EXACTLY ONE variant of
Self::ALL ties for Self::max_variant_count in items,
computed as the strict-equality test of the just-lifted
Self::count_modal_variants cardinality-count aggregate against
the scalar threshold 1. The BOOL-RETURN SHARPENING on the (set-
level × bool × statistical-aggregate × direction × argmax × unique-
tie) corner OPENING the (set-level × bool × statistical-aggregate
× direction × argmax × cardinality-count-threshold) column peer to
Self::count_modal_variants one RETURN-SHAPE axis over (set-
level × usize cardinality → set-level × bool uniqueness test
against 1) AND peer to Self::modal_variant one RETURN-SHAPE
axis over (set-level × Option<Self> first-witness → set-level ×
bool uniqueness of the witness’s tie-class). Not a fresh
substrate primitive on the index axis — the predicate emerges from
one strict-equality test of the just-lifted
Self::count_modal_variants scalar against 1, equivalently
the Vec::len equality of the declaration-order argmax witness-
collection Self::modal_variants against 1. Read moreSource§fn has_unique_antimode(items: &[Self]) -> bool
fn has_unique_antimode(items: &[Self]) -> bool
true iff EXACTLY ONE variant of
Self::ALL ties for Self::min_variant_count in items,
computed as the strict-equality test of the just-lifted
Self::count_antimodal_variants cardinality-count aggregate
against the scalar threshold 1. The BOOL-RETURN SHARPENING on
the (set-level × bool × statistical-aggregate × direction × argmin
× unique-tie) corner CLOSING the (set-level × bool × statistical-
aggregate × direction × unique-tie) 2-corner face at its argmin
arm past the just-opened Self::has_unique_mode argmax corner
one DIRECTION axis over on the modal-aggregation matrix, AND peer
to Self::count_antimodal_variants one RETURN-SHAPE axis over
(set-level × usize cardinality → set-level × bool uniqueness
test against 1) AND peer to Self::antimodal_variant one
RETURN-SHAPE axis over (set-level × Option<Self> first-witness
→ set-level × bool uniqueness of the witness’s tie-class). Not
a fresh substrate primitive on the index axis — the predicate
emerges from one strict-equality test of the just-lifted
Self::count_antimodal_variants scalar against 1,
equivalently the Vec::len equality of the declaration-order
argmin witness-collection Self::antimodal_variants against
1. Read moreSource§fn is_unique_modal_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_modal_variant_of(target: Self, items: &[Self]) -> bool
true iff target is a modal variant of items
(its per-target multiplicity coincides with Self::max_variant_count)
AND items has a unique mode (Self::count_modal_variants == 1),
computed as the conjunction of the just-lifted per-target argmax
membership predicate Self::is_modal_variant_of with the just-
lifted set-level modal-uniqueness predicate Self::has_unique_mode.
The BOOL-RETURN ARITY-LIFT opener on the (per-target × bool ×
statistical-aggregate × direction × argmax × unique-tie) corner
OPENING the (arity × unique-tie) 2-corner face at its (per-target ×
argmax) arm peer to Self::has_unique_mode (set-level × bool ×
argmax × unique-tie) one ARITY axis over AND peer to
Self::is_modal_variant_of (per-target × bool × argmax) one
UNIQUE-TIE-SHARPENING axis over. Not a fresh substrate primitive on
the index axis — the predicate emerges from the conjunction of the
per-target argmax membership predicate with the set-level modal-
uniqueness scalar, equivalently the strict-equality test of the
just-lifted first-witness Self::modal_variant projection against
Some(target). Read moreSource§fn is_unique_antimodal_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_antimodal_variant_of(target: Self, items: &[Self]) -> bool
true iff target is an
antimodal variant of items (its per-target multiplicity coincides
with Self::min_variant_count) AND items has a unique
antimode (Self::count_antimodal_variants == 1), computed as
the conjunction of the just-lifted per-target argmin membership
predicate Self::is_antimodal_variant_of with the just-lifted
set-level antimodal-uniqueness predicate
Self::has_unique_antimode. The BOOL-RETURN DIRECTION-CLOSING
corner CLOSING the (per-target × bool × statistical-aggregate ×
direction × unique-tie) 2-corner face at its argmin arm peer to
Self::is_unique_modal_variant_of one DIRECTION axis over AND
peer to Self::has_unique_antimode (set-level × bool × argmin
× unique-tie) one ARITY axis over AND peer to
Self::is_antimodal_variant_of (per-target × bool × argmin)
one UNIQUE-TIE-SHARPENING axis over. Not a fresh substrate
primitive on the index axis — the predicate emerges from the
conjunction of the per-target argmin membership predicate with
the set-level antimodal-uniqueness scalar, equivalently the
strict-equality test of the just-lifted first-witness
Self::antimodal_variant projection against Some(target). Read moreSource§fn unique_modal_variant(items: &[Self]) -> Option<Self>
fn unique_modal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a unique mode (Self::has_unique_mode
holds) AND v is the sole variant achieving Self::max_variant_count,
else None. Computed as the just-lifted set-level modal-uniqueness
bit Self::has_unique_mode guarding the just-lifted declaration-
order first-witness Self::modal_variant projection: when the
guard holds the argmax witness is unambiguous and lifted verbatim;
when the guard falsifies the projection collapses to None. The
Option<Self>-RETURN SHARPENING on the (set-level × Option<Self>
× statistical-aggregate × direction × argmax × unique-tie) corner
OPENING the (set-level × Option<Self> × statistical-aggregate ×
unique-tie) column past the four (set-level × Option<Self> ×
statistical-aggregate × direction × ordering) declaration/lex/
argmax/argmin unsharpened corners (Self::modal_variant,
Self::sorted_modal_variant, Self::antimodal_variant,
Self::sorted_antimodal_variant) one UNIQUE-TIE-SHARPENING axis
over on the modal-aggregation matrix, AND peer to
Self::has_unique_mode one RETURN-SHAPE axis over (set-level ×
bool uniqueness bit → set-level × Option<Self> witness-when-
unique) AND peer to Self::modal_variant one UNIQUE-TIE-
SHARPENING axis over (declaration-order first-witness → declaration-
order first-witness gated by uniqueness). Not a fresh substrate
primitive on the index axis — the projection emerges from a
boolean conjunction of the just-lifted set-level uniqueness bit
with the just-lifted declaration-order first-witness projection
under an Option-collapse when the guard falsifies. Read moreSource§fn sorted_unique_modal_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_modal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a unique mode
(Self::has_unique_mode holds) AND v is the sole variant of
Self::sorted_variants achieving Self::max_variant_count,
else None. Computed as the just-lifted set-level modal-
uniqueness bit Self::has_unique_mode guarding a LEX-ORDER
first-witness sweep of Self::sorted_variants keyed on
count == max — equivalently, the just-lifted
Self::sorted_modal_variant projection under the same guard.
The LEX-ORDER Option<Self>-RETURN UNIQUE-TIE SHARPENING corner
OPENING the (set-level × Option<Self> × sorted × statistical-
aggregate × direction × argmax × unique-tie) row on the MODAL-
AGGREGATION surface — the lex-ordering peer of the just-lifted
declaration-order Self::unique_modal_variant one ORDERING
axis over, peer to Self::sorted_modal_variants one UNIQUE-
TIE-SHARPENING axis over (existential >= 1 Vec of modal
witnesses → uniqueness == 1 Option<Self> collapse), AND peer
to Self::sorted_unique_missing_variant +
Self::sorted_unique_repeating_variant +
Self::sorted_unique_unique_variant one SURFACE axis over on
the equivalence-partition matrix. Not a fresh substrate
primitive on the index axis — the projection emerges from a
boolean conjunction of the set-level modal-uniqueness bit with a
lex-order first-witness Iterator::find sweep of
Self::sorted_variants under an Option-collapse when the
guard falsifies. Read moreSource§fn unique_antimodal_variant(items: &[Self]) -> Option<Self>
fn unique_antimodal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a unique antimode
(Self::has_unique_antimode holds) AND v is the sole variant
achieving Self::min_variant_count, else None. Computed as the
just-lifted set-level antimodal-uniqueness bit
Self::has_unique_antimode guarding the declaration-order first-
witness Self::antimodal_variant projection: when the guard holds
the argmin witness is unambiguous and lifted verbatim; when the guard
falsifies the projection collapses to None. The Option<Self>-
RETURN SHARPENING on the (set-level × Option<Self> × statistical-
aggregate × direction × argmin × unique-tie) corner CLOSING the
(set-level × Option<Self> × statistical-aggregate × direction ×
unique-tie) 2-corner face at its argmin arm past the just-opened
Self::unique_modal_variant argmax corner one DIRECTION axis over
on the modal-aggregation matrix, AND peer to
Self::has_unique_antimode one RETURN-SHAPE axis over (set-level ×
bool uniqueness bit → set-level × Option<Self> witness-when-
unique) AND peer to Self::antimodal_variant one UNIQUE-TIE-
SHARPENING axis over (declaration-order first-witness → declaration-
order first-witness gated by uniqueness). Not a fresh substrate
primitive on the index axis — the projection emerges from a boolean
conjunction of the just-lifted set-level antimodal-uniqueness bit
with the just-lifted declaration-order first-argmin witness
projection under an Option-collapse when the guard falsifies. Read moreSource§fn sorted_unique_antimodal_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_antimodal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a unique antimode
(Self::has_unique_antimode holds) AND v is the sole variant
of Self::sorted_variants achieving Self::min_variant_count,
else None. Computed as the just-lifted set-level antimodal-
uniqueness bit Self::has_unique_antimode guarding a LEX-ORDER
first-witness sweep of Self::sorted_variants keyed on
count == min — equivalently, the just-lifted
Self::sorted_antimodal_variant projection under the same
guard. The LEX-ORDER Option<Self>-RETURN UNIQUE-TIE SHARPENING
corner EXHAUSTIVELY CLOSING the (set-level × Option<Self> ×
statistical-aggregate × direction × ordering × unique-tie) 2×2×2
= 8-corner cube at its FINAL corner past the (argmax, declaration)
Self::unique_modal_variant opener, the (argmax, lex)
Self::sorted_unique_modal_variant just-lifted argmax-lex
closure, and the (argmin, declaration) Self::unique_antimodal_variant
argmin-declaration closure — the argmin-lex arm one ORDERING axis
over from Self::unique_antimodal_variant AND one DIRECTION axis
over from Self::sorted_unique_modal_variant. Not a fresh
substrate primitive on the index axis — the projection emerges
from a boolean conjunction of the set-level antimodal-uniqueness
bit with a lex-order first-witness Iterator::find sweep of
Self::sorted_variants under an Option-collapse when the
guard falsifies. Read moreSource§fn sorted_unique_extremal_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_extremal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE extremal
witness (Self::has_unique_extremal_variant holds) AND v is
the sole variant of Self::sorted_variants achieving EITHER
Self::max_variant_count OR Self::min_variant_count, else
None. Computed as the just-lifted set-level extremal-union
uniqueness bit Self::has_unique_extremal_variant guarding a
LEX-ORDER first-witness sweep of Self::sorted_variants keyed
on count == max || count == min — equivalently, the just-
lifted Self::sorted_extremal_variant projection under the
same guard. The LEX-ORDER Option<Self>-RETURN UNIQUE-TIE
SHARPENING corner OPENING the (set-level × Option<Self> ×
statistical-aggregate × direction-composition × ordering ×
unique-tie) column past the (declaration, union) opener
Self::unique_extremal_variant one ORDERING axis over on the
modal-aggregation matrix — the union-lex arm one COMBINATOR
axis over from Self::sorted_unique_modal_variant /
Self::sorted_unique_antimodal_variant which just closed the
direction-anchored 8-corner cube at the (argmax, lex) and
(argmin, lex) corners. Not a fresh substrate primitive on the
index axis — the projection emerges from a boolean conjunction
of the set-level extremal-union uniqueness bit with a lex-order
first-witness Iterator::find sweep of Self::sorted_variants
under an Option-collapse when the guard falsifies. Read moreSource§fn sorted_unique_middle_band_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_middle_band_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE strict-
interior witness (Self::has_unique_middle_band_variant holds)
AND v is the sole variant of Self::sorted_variants with
occurrence-count STRICTLY BETWEEN Self::max_variant_count AND
Self::min_variant_count, else None. Computed as the just-
lifted set-level middle-band uniqueness bit
Self::has_unique_middle_band_variant guarding the LEX-ORDER
strict-interior first-witness Self::sorted_middle_band_variant
projection: when the guard holds the complement witness is
unambiguous and lifted verbatim; when the guard falsifies the
projection collapses to None. The LEX-ORDER Option<Self>-
RETURN UNIQUE-TIE SHARPENING corner CLOSING the complement arm
of the (set-level × sorted × Option<Self> × direction-
composition × combinator × unique-tie) row past the just-opened
UNION arm Self::sorted_unique_extremal_variant one COMBINATOR
axis over on the modal-aggregation matrix AND peer to
Self::unique_middle_band_variant one ORDERING axis over
(declaration-order → lex-order strict-interior first-witness-
when-unique) AND peer to Self::sorted_middle_band_variant
one UNIQUE-TIE-SHARPENING axis over (unsharpened lex-order
strict-interior first-witness → uniqueness-gated lex-order
strict-interior first-witness). Not a fresh substrate primitive
on the index axis — the projection emerges from a boolean
conjunction of the just-lifted set-level middle-band uniqueness
bit with the just-lifted lex-order strict-interior first-witness
projection under an Option-collapse when the guard falsifies. Read moreSource§fn sorted_unique_bimodal_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_bimodal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE
intersection-band witness (Self::has_unique_bimodal_variant
holds) AND v is the sole variant of Self::sorted_variants
whose occurrence-count sits at BOTH Self::max_variant_count
AND Self::min_variant_count simultaneously, else None.
Computed as the just-lifted set-level bimodal uniqueness bit
Self::has_unique_bimodal_variant guarding the LEX-ORDER
uniformity-collapse first-witness Self::sorted_bimodal_variant
projection: when the guard holds the intersection witness is
unambiguous and lifted verbatim; when the guard falsifies the
projection collapses to None. The LEX-ORDER Option<Self>-
RETURN UNIQUE-TIE SHARPENING corner CLOSING the intersection
arm of the (set-level × sorted × Option<Self> × direction-
composition × combinator × unique-tie) row past the just-opened
UNION arm Self::sorted_unique_extremal_variant AND the just-
closed COMPLEMENT arm Self::sorted_unique_middle_band_variant
one COMBINATOR axis over on the modal-aggregation matrix AND
EXHAUSTIVELY CLOSING the (set-level × sorted × Option<Self> ×
direction-composition × combinator × ordering × unique-tie)
3×2 face at its FINAL SIXTH TILE — the (intersection, lex)
corner past the (union, declaration), (union, lex),
(complement, declaration), (complement, lex), (intersection,
declaration) five closers. Peer to
Self::unique_bimodal_variant one ORDERING axis over
(declaration-order → lex-order intersection first-witness-when-
unique) AND peer to Self::sorted_bimodal_variant one
UNIQUE-TIE-SHARPENING axis over (unsharpened lex-order
intersection first-witness → uniqueness-gated lex-order
intersection first-witness). Not a fresh substrate primitive on
the index axis — the projection emerges from a boolean
conjunction of the just-lifted set-level bimodal uniqueness bit
with the just-lifted lex-order intersection first-witness
projection under an Option-collapse when the guard falsifies. Read moreSource§fn is_extremal_variant_of(target: Self, items: &[Self]) -> bool
fn is_extremal_variant_of(target: Self, items: &[Self]) -> bool
true iff target sits on the
modal (argmax) band OR the antimodal (argmin) band of the per-
variant occurrence histogram over items, computed as the
DIRECTION-AGNOSTIC UNION of the just-lifted per-target argmax
membership predicate Self::is_modal_variant_of with the
just-lifted per-target argmin membership predicate
Self::is_antimodal_variant_of under ||. The BOOL-RETURN
DIRECTION-AGNOSTIC UNION OPENER on the (per-target × bool ×
statistical-aggregate × direction-agnostic × union) corner
OPENING the (per-target × bool × statistical-aggregate ×
direction-composition) column past the four (per-target × bool ×
statistical-aggregate × direction × unsharpened/unique-tie)
direction-anchored corners (Self::is_modal_variant_of,
Self::is_antimodal_variant_of, Self::is_unique_modal_variant_of,
Self::is_unique_antimodal_variant_of) one DIRECTION-
COMPOSITION axis over on the modal-aggregation matrix. Not a
fresh substrate primitive on the index axis — the predicate
emerges from ONE boolean disjunction of the two direction-
anchored per-target argmax/argmin membership predicates,
equivalently the non-emptiness-guarded disjunction test of the
just-lifted Self::count_occurrences_of scalar against
EITHER Self::max_variant_count OR Self::min_variant_count. Read moreSource§fn is_bimodal_variant_of(target: Self, items: &[Self]) -> bool
fn is_bimodal_variant_of(target: Self, items: &[Self]) -> bool
true iff target’s per-slot count in items equals
BOTH Self::max_variant_count AND Self::min_variant_count
simultaneously, computed as the boolean CONJUNCTION of
Self::is_modal_variant_of and Self::is_antimodal_variant_of.
The BOOL-RETURN closer on the (per-target × bool × statistical-
aggregate × direction-composition × combinator) 2-corner face at
its && CONJUNCTION arm past the just-opened || DISJUNCTION arm
Self::is_extremal_variant_of one COMBINATOR axis over, AND the
per-target × flat-histogram-diagonal witness on the (per-target ×
bool × statistical-aggregate × direction-composition) column. Not
a fresh substrate primitive on the index axis — the predicate
emerges from ONE boolean AND on the two just-lifted direction-
anchored membership predicates, equivalently the count-band
coincidence identity count(target, items) == max_variant_count(items) == min_variant_count(items) on non-empty
slices (where the max/min bands COINCIDE on the flat-histogram
diagonal at target). Read moreSource§fn count_bimodal_variants(items: &[Self]) -> usize
fn count_bimodal_variants(items: &[Self]) -> usize
usize SET-LEVEL
count of variants of Self::ALL for which
Self::is_bimodal_variant_of holds against items, SHARPENED past
the naive filter-count reduction over the per-target predicate via
the uniformity-collapse identity: on non-empty slices EVERY variant
satisfies the flat-diagonal predicate iff Self::is_uniform holds
(max == min), so the count collapses to Self::CARDINALITY on
flat-histogram non-empty slices and to 0 on every non-flat non-
empty slice AND on the empty slice. The USIZE-RETURN CLOSER on the
(set-level × usize × statistical-aggregate × direction-composition ×
combinator) 2-corner face at its && CONJUNCTION arm one COMBINATOR
axis over from a prospective disjunction sibling
count_extremal_variants, AND the direct SET-LEVEL ARITY LIFT of
the just-lifted (per-target × bool × statistical-aggregate ×
direction-composition × intersection) Self::is_bimodal_variant_of
corner one ARITY axis over on the modal-aggregation matrix, AND peer
to Self::count_modal_variants one DIRECTION-COMPOSITION axis over
on the (set-level × usize × statistical-aggregate) cardinality-count
row (count_modal_variants — argmax filter-count; THIS —
intersection scalar branch). Not a fresh substrate primitive on the
index axis — the count emerges from one is_empty()-guarded scalar
branch on the just-lifted Self::is_uniform projection, returning
Self::CARDINALITY on flat-histogram non-empty slices and 0
otherwise. The sharpening replaces the naive T::ALL.iter().filter( |&v| T::is_bimodal_variant_of(v, items)).count() sweep
(O(T::CARDINALITY² * n) — the per-target predicate itself costs
O(T::CARDINALITY * n)) with a single Self::is_uniform sweep
(O(T::CARDINALITY * n)), inheriting the max/min-fold cost of the
underlying aggregate exactly once. Read moreSource§fn count_extremal_variants(items: &[Self]) -> usize
fn count_extremal_variants(items: &[Self]) -> usize
usize SET-LEVEL count of
variants of Self::ALL for which Self::is_extremal_variant_of
holds against items, SHARPENED past the naive filter-count reduction
via the inclusion-exclusion identity
|A ∪ B| = |A| + |B| − |A ∩ B|
against the just-lifted direction-anchored cardinality-count pair
Self::count_modal_variants + Self::count_antimodal_variants and
the intersection sibling Self::count_bimodal_variants. The
USIZE-RETURN CLOSER on the (set-level × usize × statistical-aggregate ×
direction-composition × combinator) 2-corner cardinality-count face at
its || DISJUNCTION arm past the just-closed && CONJUNCTION arm
Self::count_bimodal_variants one COMBINATOR axis over on the
modal-aggregation matrix, AND the direct SET-LEVEL ARITY LIFT of the
just-lifted (per-target × bool × statistical-aggregate ×
direction-composition × union) Self::is_extremal_variant_of corner
one ARITY axis over, AND peer to Self::count_modal_variants +
Self::count_antimodal_variants one COMBINATOR axis over on the
(set-level × usize × statistical-aggregate × direction-composition)
cardinality-count row. Not a fresh substrate primitive on the index
axis — the count emerges from ONE is_empty() guard + ONE
inclusion-exclusion arithmetic on the three just-lifted set-level
cardinality-count aggregates, replacing the naive
T::ALL.iter().filter(|&v| T::is_extremal_variant_of(v, items)).count()
sweep (O(T::CARDINALITY² * n) — the per-target predicate itself
costs O(T::CARDINALITY * n)) with three max/min-fold sweeps
(O(T::CARDINALITY * n) each) that ALREADY run inside the direction
siblings, so on any callsite that also consumes
Self::count_modal_variants or Self::count_antimodal_variants
the arithmetic collapses to two arithmetic ops and one comparison
against a cached fold pair, inheriting the max/min-fold cost of the
underlying aggregates exactly once. Read moreSource§fn is_middle_band_variant_of(target: Self, items: &[Self]) -> bool
fn is_middle_band_variant_of(target: Self, items: &[Self]) -> bool
true iff the slice is non-empty
AND target’s per-slot count in items sits STRICTLY between
Self::min_variant_count and Self::max_variant_count
(equivalently, target is NEITHER at the argmax band NOR at the
argmin band), computed as the boolean CONJUNCTION of a non-empty
guard AND the negation of Self::is_extremal_variant_of. The
BOOL-RETURN OPENER on the (per-target × bool × statistical-
aggregate × direction-composition × complement) middle-band corner
past the just-closed (per-target × bool × statistical-aggregate ×
direction-composition × combinator) 2-corner union/intersection
face — the direct De Morgan COMPLEMENT of Self::is_extremal_variant_of
on non-empty slices, closing the (extreme / middle) partition of
Self::ALL on every non-empty slice at every target. Not a
fresh substrate primitive on the index axis — the predicate emerges
from ONE non-empty guard AND one boolean negation of the just-
lifted (per-target × bool × direction-composition × union)
Self::is_extremal_variant_of corner, equivalently the count-
band strict-between test min < count < max on non-empty slices. Read moreSource§fn count_middle_band_variants(items: &[Self]) -> usize
fn count_middle_band_variants(items: &[Self]) -> usize
usize SET-LEVEL count of variants of Self::ALL for which
Self::is_middle_band_variant_of holds against items, SHARPENED
past the naive filter-count reduction via the De Morgan complement
identity |middle| = T::CARDINALITY - |extremal| on non-empty
slices against the just-lifted (set-level × usize × direction-
composition × union) Self::count_extremal_variants cardinality-
count aggregate. The USIZE-RETURN CLOSER on the (set-level × usize
× statistical-aggregate × direction-composition × complement)
middle-band corner ARITY-LIFTING Self::is_middle_band_variant_of
one ARITY axis over on the modal-aggregation matrix, AND the direct
SET-LEVEL COMPLEMENT of the just-lifted (set-level × usize ×
statistical-aggregate × direction-composition × union)
Self::count_extremal_variants corner one COMPLEMENT axis over,
closing the (extreme / middle) partition on the set-level usize
row. Not a fresh substrate primitive on the index axis — the count
emerges from ONE is_empty() guard + ONE subtraction on the just-
lifted set-level union cardinality-count aggregate, replacing the
naive
T::ALL.iter().filter(|&v| T::is_middle_band_variant_of(v, items)).count()
sweep (O(T::CARDINALITY² * n) — the per-target predicate itself
costs O(T::CARDINALITY * n) via the nested extremal test) with
one subtraction against a cached Self::count_extremal_variants
aggregate that ALREADY runs inside the union sibling, so on any
callsite that also consumes Self::count_extremal_variants the
arithmetic collapses to one arithmetic op against the cached fold,
inheriting the max/min-fold cost of the underlying aggregate
exactly once. Read moreSource§fn has_middle_band_variant(items: &[Self]) -> bool
fn has_middle_band_variant(items: &[Self]) -> bool
true iff
AT LEAST ONE variant of Self::ALL carries an occurrence-count
strictly greater than Self::min_variant_count AND strictly less
than Self::max_variant_count, computed as the strict-lower-bound
test of the just-lifted Self::count_middle_band_variants
cardinality-count aggregate against the scalar threshold 1. The
BOOL-RETURN OPENER on the (set-level × bool × statistical-aggregate ×
direction-composition × complement × existential) middle-band
existence corner peer to Self::count_middle_band_variants one
RETURN-SHAPE axis over (set-level × usize cardinality → set-level ×
bool existential lift against >= 1) AND the direct SET-LEVEL
EXISTENTIAL LIFT of the (per-target × bool × statistical-aggregate ×
direction-composition × complement)
Self::is_middle_band_variant_of corner one ARITY axis over on the
modal-aggregation matrix. Not a fresh substrate primitive on the
index axis — the predicate emerges from one strict-lower-bound test
of the just-lifted Self::count_middle_band_variants scalar
against 1, equivalently the disjunction over Self::ALL of the
per-target Self::is_middle_band_variant_of predicate. Cheaper
than the count on hot paths that only need an existence witness —
the count aggregate’s T::CARDINALITY - count_extremal arithmetic
runs unchanged, but the downstream consumer binds a typed bool bit
against the composed threshold rather than a scalar-and-compare
composition. Read moreSource§fn has_bimodal_variant(items: &[Self]) -> bool
fn has_bimodal_variant(items: &[Self]) -> bool
true iff
AT LEAST ONE variant of Self::ALL carries an occurrence-count
EQUAL to BOTH Self::min_variant_count AND
Self::max_variant_count (equivalently, the slice is non-empty
AND every variant sits at BOTH extremes simultaneously —
Self::is_uniform holds on the non-empty guard), computed as
the strict-lower-bound test of the just-lifted
Self::count_bimodal_variants cardinality-count aggregate
against the scalar threshold 1. The BOOL-RETURN CLOSER on the
(set-level × bool × statistical-aggregate × direction-composition
× intersection × existential) bimodal existence corner peer to
Self::count_bimodal_variants one RETURN-SHAPE axis over
(set-level × usize cardinality → set-level × bool existential
lift against >= 1) AND the direct SET-LEVEL EXISTENTIAL LIFT of
the (per-target × bool × statistical-aggregate × direction-
composition × intersection) Self::is_bimodal_variant_of corner
one ARITY axis over on the modal-aggregation matrix AND peer to
the just-opened Self::has_middle_band_variant one DIRECTION-
COMPOSITION axis over (intersection && arm vs the complement
!extremal arm — jointly with Self::has_extremal_variant’s
prospective union || arm the three form the set-level
existential trichotomy on the modal-aggregation matrix). Not a
fresh substrate primitive on the index axis — the predicate
emerges from one strict-lower-bound test of the just-lifted
Self::count_bimodal_variants scalar against 1, equivalently
the non-empty guard AND Self::is_uniform via the uniformity-
collapse identity, equivalently the disjunction over
Self::ALL of the per-target
Self::is_bimodal_variant_of predicate. Read moreSource§fn has_extremal_variant(items: &[Self]) -> bool
fn has_extremal_variant(items: &[Self]) -> bool
true iff
AT LEAST ONE variant of Self::ALL carries an occurrence-count
EQUAL to EITHER Self::min_variant_count OR
Self::max_variant_count, SHARPENED via the union-arm non-
emptiness collapse: on ANY non-empty slice the argmax band is
non-empty (SOME variant achieves the max count >= 1, and that
variant is trivially at the argmax extreme via
Self::is_modal_variant_of, so
Self::is_extremal_variant_of holds on it via the disjunction
arm), and the empty slice has no target to sit anywhere. The
BOOL-RETURN CLOSER on the (set-level × bool × statistical-
aggregate × direction-composition × union × existential) extremal
existence corner peer to Self::count_extremal_variants one
RETURN-SHAPE axis over (set-level × usize cardinality → set-
level × bool existential lift against >= 1) AND the direct
SET-LEVEL EXISTENTIAL LIFT of the (per-target × bool ×
statistical-aggregate × direction-composition × union)
Self::is_extremal_variant_of corner one ARITY axis over on
the modal-aggregation matrix AND peer to
Self::has_middle_band_variant +
Self::has_bimodal_variant one DIRECTION-COMPOSITION axis
over — the three form the set-level existential trichotomy on
the modal-aggregation matrix (union / intersection / complement
of the two direction-anchored membership predicates). Not a
fresh substrate primitive on the index axis — the predicate
collapses to the pre-existing standard-library
!<[Self]>::is_empty() slice-empty bit past a NON-EMPTINESS
COLLAPSE proof; the count-composition body
T::count_extremal_variants(items) >= 1 and the existential-
lift body T::ALL.iter().any(|v| T::is_extremal_variant_of(v, items))
are the equivalent-but-slower canonical forms the identities
pin against. Read moreSource§fn extremal_variants(items: &[Self]) -> Vec<Self>
fn extremal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER witness-collection of EVERY variant
of Self::ALL for which Self::is_extremal_variant_of holds
against items (equivalently, whose per-slot count equals EITHER
Self::max_variant_count OR Self::min_variant_count),
preserving Self::ALL’s canonical declaration order and
returning the empty vector when items is empty. The DIRECTION-
COMPOSITION UNION opener on the (set-level × Vec<Self> ×
statistical-aggregate × direction-composition × union) corner
past the direction-anchored Self::modal_variants +
Self::antimodal_variants pair one DIRECTION-COMPOSITION axis
over. Direct SET-LEVEL ARITY LIFT of the (per-target × bool ×
direction-composition × union) Self::is_extremal_variant_of
corner one ARITY axis over, AND peer to
Self::count_extremal_variants one RETURN-SHAPE axis over
(usize cardinality → Vec<Self> witness-collection). Not a
fresh substrate primitive on the index axis — the projection
emerges from ONE is_empty() guard AND ONE max/min-fold pair AND
ONE T::CARDINALITY-bounded filter sweep whose predicate binds
Self::count_occurrences_of against the pair, guarded so &[]
maps to Vec::new() past the (max == min == 0, every-count == 0)
degenerate arm where an unguarded sweep would silently return
T::ALL.to_vec(). Read moreSource§fn middle_band_variants(items: &[Self]) -> Vec<Self>
fn middle_band_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER witness-collection of EVERY variant of
Self::ALL for which Self::is_middle_band_variant_of holds
against items (equivalently, whose per-slot count sits STRICTLY
between Self::min_variant_count and Self::max_variant_count),
preserving Self::ALL’s canonical declaration order and returning
the empty vector when items is empty. The DIRECTION-COMPOSITION
COMPLEMENT closer on the (set-level × Vec<Self> × statistical-
aggregate × direction-composition × complement) corner CLOSING the
(set-level × Vec<Self> × direction-composition) row past the
direction-anchored Self::modal_variants + Self::antimodal_variants
pair AND the just-opened UNION arm Self::extremal_variants one
DIRECTION-COMPOSITION axis over. Direct SET-LEVEL ARITY LIFT of the
(per-target × bool × direction-composition × complement)
Self::is_middle_band_variant_of corner one ARITY axis over, AND
peer to Self::count_middle_band_variants one RETURN-SHAPE axis
over (usize cardinality → Vec<Self> witness-collection). Not a
fresh substrate primitive on the index axis — the projection emerges
from ONE is_empty() guard AND ONE max/min-fold pair AND ONE
T::CARDINALITY-bounded filter sweep whose predicate binds
Self::count_occurrences_of against the pair via the STRICT
interior test c != max && c != min, guarded so &[] maps to
Vec::new() past the (max == min == 0, every-count == 0) degenerate
arm where an unguarded sweep would silently return Vec::new() for
the WRONG reason (every variant is extremal on the empty slice, not
middle-band). Read moreSource§fn sorted_middle_band_variants(items: &[Self]) -> Vec<Self>
fn sorted_middle_band_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER witness-collection of EVERY variant of
Self::sorted_variants for which
Self::is_middle_band_variant_of holds against items
(equivalently, whose per-slot count sits STRICTLY between
Self::min_variant_count and Self::max_variant_count),
preserving Self::sorted_variants’s canonical ASCII-lex order
and returning the empty vector when items is empty. The
LEX-ORDER peer of Self::middle_band_variants one ORDERING
axis over, CLOSING the (set-level × Vec<Self> × statistical-
aggregate × direction-composition × complement × ordering)
2-corner face at its lex-arm past the declaration-arm the
sibling Self::middle_band_variants opened. Not a fresh
substrate primitive on the index axis — the projection emerges
from ONE is_empty() guard + ONE max/min-fold pair + ONE
T::CARDINALITY-bounded filter sweep over
Self::sorted_variants whose predicate binds
Self::count_occurrences_of against the pair via the STRICT
interior test c != max && c != min. Read moreSource§fn sorted_extremal_variants(items: &[Self]) -> Vec<Self>
fn sorted_extremal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER witness-collection of EVERY variant of
Self::sorted_variants for which
Self::is_extremal_variant_of holds against items
(equivalently, whose per-slot count sits AT either
Self::max_variant_count or Self::min_variant_count),
preserving Self::sorted_variants’s canonical ASCII-lex order
and returning the empty vector when items is empty. The
LEX-ORDER peer of Self::extremal_variants one ORDERING axis
over, CLOSING the (set-level × Vec<Self> × statistical-
aggregate × direction-composition × union × ordering) 2-corner
face at its lex-arm past the declaration-arm the sibling
Self::extremal_variants opened. Not a fresh substrate
primitive on the index axis — the projection emerges from ONE
is_empty() guard + ONE max/min-fold pair + ONE
T::CARDINALITY-bounded filter sweep over
Self::sorted_variants whose predicate binds
Self::count_occurrences_of against the pair via the UNION
test c == max || c == min. Read moreSource§fn bimodal_variants(items: &[Self]) -> Vec<Self>
fn bimodal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER witness-collection of EVERY variant
of Self::ALL for which Self::is_bimodal_variant_of holds
against items (equivalently, whose per-slot count sits at BOTH
Self::max_variant_count AND Self::min_variant_count
simultaneously), preserving Self::ALL’s canonical declaration
order and returning the empty vector when items is empty. The
DIRECTION-COMPOSITION INTERSECTION opener on the (set-level ×
Vec<Self> × statistical-aggregate × direction-composition ×
intersection) corner OPENING the (set-level × Vec<Self> ×
direction-composition × combinator) 2-corner flat-diagonal face
at its && CONJUNCTION arm past the just-lifted UNION arm
Self::extremal_variants one COMBINATOR axis over on the
modal-aggregation matrix. Direct SET-LEVEL ARITY LIFT of the
(per-target × bool × direction-composition × intersection)
Self::is_bimodal_variant_of corner one ARITY axis over, AND
peer to Self::count_bimodal_variants one RETURN-SHAPE axis
over (usize cardinality → Vec<Self> witness-collection) via
the SAME uniformity-collapse SHARPENING (which cuts one
algorithmic factor of T::CARDINALITY off the naive filter
sweep — a two-value dichotomy over T::ALL.to_vec() /
Vec::new() gated by Self::is_uniform rather than a per-
target predicate re-derivation of the max and min folds). Read moreSource§fn sorted_bimodal_variants(items: &[Self]) -> Vec<Self>
fn sorted_bimodal_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER witness-collection of EVERY variant of
Self::sorted_variants for which Self::is_bimodal_variant_of
holds against items (equivalently, whose per-slot count sits at
BOTH Self::max_variant_count AND Self::min_variant_count
simultaneously), preserving Self::sorted_variants’s canonical
ASCII-lex order and returning the empty vector when items is
empty. The LEX-ORDER peer of Self::bimodal_variants one
ORDERING axis over, CLOSING the (set-level × Vec<Self> ×
statistical-aggregate × direction-composition × intersection ×
ordering) 2-corner face at its lex-arm past the declaration-arm
the sibling Self::bimodal_variants opened. Not a fresh
substrate primitive on the index axis — the projection emerges
from the SAME uniformity-collapse SHARPENING as
Self::bimodal_variants (if items.is_empty() || !T::is_uniform(items) { Vec::new() } else { T::sorted_variants() })
with T::sorted_variants() in place of T::ALL.to_vec() on the
uniform arm — the lex axis surfaces ONLY in the returned walk
order. Read moreSource§fn extremal_variant(items: &[Self]) -> Option<Self>
fn extremal_variant(items: &[Self]) -> Option<Self>
Option<Self> DECLARATION-ORDER-FIRST-WITNESS over the direction-
composition UNION of Self::max_variant_count and
Self::min_variant_count, reporting the FIRST variant of
Self::ALL (walked in declaration order) whose per-target count
hits AT LEAST ONE of the two histogram extremes, or None when
items is empty. The OPTION-RETURN opener on the direction-
composition axis peer to Self::modal_variant (argmax first-
witness, declaration) and Self::antimodal_variant (argmin
first-witness, declaration) one DIRECTION-COMPOSITION axis over
via the disjunctive extremal predicate — the (set-level ×
Option<Self> × statistical-aggregate × direction-composition ×
union) row OPENS its declaration-order first-witness corner past
the direction-anchored (argmax, argmin) pair one DIRECTION-
COMPOSITION axis over on the modal-aggregation matrix. Direct
FIRST-WITNESS PROJECTION of the (set-level × Vec<Self> ×
statistical-aggregate × direction-composition × union)
Self::extremal_variants corner one RETURN-SHAPE axis over
(Vec<Self> witness-collection → Option<Self> first-witness),
AND peer to Self::has_extremal_variant one RETURN-SHAPE axis
over (bool existence → Option<Self> first-witness), AND direct
SET-LEVEL ARITY LIFT of the (per-target × bool × direction-
composition × union) Self::is_extremal_variant_of corner one
ARITY axis over via the FIRST-witness projection over the per-
target predicate. Not a fresh substrate primitive on the index
axis — the projection emerges from ONE is_empty() guard AND ONE
max/min-fold pair AND ONE T::CARDINALITY-bounded declaration-
order find sweep whose predicate binds
Self::count_occurrences_of against the pair via the union
test c == max || c == min, guarded so &[] maps to None past
the (max == min == 0, every-count == 0) degenerate arm where an
unguarded sweep would silently return Some(T::first()) (every
variant satisfies count == 0 == max == min vacuously — the
WRONG structural answer past the non-emptiness precondition
Self::is_extremal_variant_of carries). Read moreSource§fn sorted_extremal_variant(items: &[Self]) -> Option<Self>
fn sorted_extremal_variant(items: &[Self]) -> Option<Self>
Option<Self> LEX-ORDER-FIRST-WITNESS over the
Self::variant_counts histogram under the DIRECTION-
COMPOSITION UNION predicate, reporting the FIRST variant of
Self::sorted_variants (walked in LEX order under the
ASCII-sort_unstable_by_key(label) discriminator) whose per-
target count equals EITHER Self::max_variant_count OR
Self::min_variant_count, or None when items is empty.
The LEX-ORDER peer of Self::extremal_variant on the
(declaration, lex) ordering axis of the (set-level ×
Option<Self> × statistical-aggregate × direction-composition ×
union) column — CLOSES the lex arm past the declaration arm the
sibling Self::extremal_variant opened, completing the
(set-level × Option<Self> × direction-composition × union ×
ordering) 2-corner face at both corners. Where
Self::extremal_variant walks Self::ALL in DECLARATION
order and commits at the first variant satisfying the union
predicate c == max || c == min, this projection walks
Self::sorted_variants in LEX order and commits at the first
variant satisfying the SAME union predicate under the ASCII-
sort_unstable_by_key(label) discriminator. The two projections
AGREE byte-for-byte on every implementor whose declaration order
coincides with the ASCII-lex order of its labels (a common case
for enums whose variants happen to be declared in
alphabetically-sorted order) AND on every slice whose union band
covers all of Self::ALL (the flat-histogram fixpoints
T::ALL, T::ALL ++ T::ALL, &[] degenerately-empty guard,
and every matching-singleton at cardinality >= 2 where every
variant satisfies c == max || c == min); they BIFURCATE at the
smallest slice whose union band excludes the ambient
T::sorted_first() in some non-flat middle-band configuration
AND whose declaration order diverges from lex order across that
band. Not a fresh substrate primitive on the index axis — the
projection emerges from the same is_empty() guard + max/min-
fold pair + find sweep, differing only in the substrate
primitive the sweep routes through
(Self::sorted_variants rather than Self::ALL). Read moreSource§fn middle_band_variant(items: &[Self]) -> Option<Self>
fn middle_band_variant(items: &[Self]) -> Option<Self>
Option<Self> DECLARATION-ORDER-FIRST-WITNESS over the
Self::variant_counts histogram under the DIRECTION-
COMPOSITION COMPLEMENT predicate, reporting the FIRST variant
of Self::ALL (walked in DECLARATION order) whose per-target
count sits STRICTLY between Self::min_variant_count and
Self::max_variant_count (equivalently, whose count neither
tops the argmax band NOR bottoms the argmin band), or None
when items is empty OR every variant sits at one of the two
extremes. The COMPLEMENT-arm OPENER on the (set-level ×
Option<Self> × direction-composition × ordering) row past the
(set-level × Option<Self> × direction-composition × union ×
ordering) 2-corner face the (Self::extremal_variant,
Self::sorted_extremal_variant) pair just closed one
COMBINATOR axis over via De Morgan complement — where the union
arm walks with c == max || c == min, THIS complement arm
walks with c != max && c != min. Peer to
Self::middle_band_variants one RETURN-SHAPE axis over
(Vec<Self> → Option<Self> first-witness), peer to
Self::has_middle_band_variant one RETURN-SHAPE axis over
(bool → Option<Self>), peer to Self::count_middle_band_variants
one RETURN-SHAPE axis over (usize → Option<Self>), and
peer to Self::extremal_variant one COMBINATOR axis over
(union → complement) via the STRICT interior conjunction
SHARPENING the union disjunction’s OR into the complement
conjunction’s AND-NOT. Read moreSource§fn sorted_middle_band_variant(items: &[Self]) -> Option<Self>
fn sorted_middle_band_variant(items: &[Self]) -> Option<Self>
Option<Self> LEX-ORDER-FIRST-WITNESS over
the Self::variant_counts histogram under the DIRECTION-
COMPOSITION COMPLEMENT predicate, reporting the FIRST variant
of Self::sorted_variants (walked in LEX order under the
ASCII-sort_unstable_by_key(label) discriminator) whose per-
target count sits STRICTLY between Self::min_variant_count
and Self::max_variant_count (equivalently, whose count
neither tops the argmax band NOR bottoms the argmin band), or
None when items is empty OR every variant sits at one of
the two extremes. The LEX-ORDER peer of
Self::middle_band_variant on the (declaration, lex) ordering
axis of the (set-level × Option<Self> × statistical-aggregate
× direction-composition × complement) column — CLOSES the lex
arm past the declaration arm the sibling
Self::middle_band_variant opened, completing the (set-level
× Option<Self> × direction-composition × complement ×
ordering) 2-corner face at both corners. Where
Self::middle_band_variant walks Self::ALL in DECLARATION
order and commits at the first variant satisfying the STRICT
interior conjunction c != max && c != min, this projection
walks Self::sorted_variants in LEX order and commits at the
first variant satisfying the SAME strict interior conjunction
under the ASCII-sort_unstable_by_key(label) discriminator. The
two projections AGREE byte-for-byte on every implementor whose
declaration order coincides with the ASCII-lex order of its
labels (a common case for enums whose variants happen to be
declared in alphabetically-sorted order) AND on every slice
whose middle band is EMPTY (None on both sides via the shared
flat-histogram + matching-singleton None fixpoints); they
BIFURCATE at the smallest slice whose middle band is non-empty
AND whose declaration order diverges from lex order across that
band. Not a fresh substrate primitive on the index axis — the
projection emerges from the same is_empty() guard + max/min-
fold pair + find sweep as the declaration-order sibling,
differing only in the substrate primitive the sweep routes
through (Self::sorted_variants rather than Self::ALL)
AND in NOTHING else on the predicate axis. Read moreSource§fn bimodal_variant(items: &[Self]) -> Option<Self>
fn bimodal_variant(items: &[Self]) -> Option<Self>
Option<Self> DECLARATION-ORDER-FIRST-WITNESS over the
Self::variant_counts histogram under the DIRECTION-
COMPOSITION INTERSECTION predicate, reporting the FIRST variant
of Self::ALL (walked in declaration order) whose per-target
count equals BOTH Self::max_variant_count AND
Self::min_variant_count simultaneously (equivalently, whose
count sits at the flat-diagonal collapse where max == min), or
None when items is empty OR the histogram is non-flat
(max != min pins a strict direction split, so NO variant hits
both extremes). The DECLARATION-ORDER opener on the (set-level
× Option<Self> × direction-composition × intersection ×
ordering) 2-corner face, OPENING the intersection arm of the
(set-level × Option<Self> × direction-composition × ordering)
row past the union arm the (Self::extremal_variant,
Self::sorted_extremal_variant) pair closed one COMBINATOR
axis over AND past the complement arm the
(Self::middle_band_variant, Self::sorted_middle_band_variant)
pair closed one COMBINATOR axis over via the flat-diagonal
predicate c == max && c == min (equivalently max == min,
the uniformity-collapse identity). Not a fresh substrate
primitive on the index axis — the projection emerges from the
SAME uniformity-collapse SHARPENING as
Self::bimodal_variants (if items.is_empty() || !T::is_uniform(items) { None } else { T::ALL.first().copied() })
with .first().copied() in place of .to_vec() on the uniform
arm — the Option<Self> first-witness projection surfaces
ONLY in the truncation from the full witness collection to its
declaration-order head. Read moreSource§fn sorted_bimodal_variant(items: &[Self]) -> Option<Self>
fn sorted_bimodal_variant(items: &[Self]) -> Option<Self>
Option<Self> LEX-ORDER-FIRST-WITNESS over the
Self::variant_counts histogram under the DIRECTION-
COMPOSITION INTERSECTION predicate, reporting the FIRST variant
of Self::sorted_variants (walked in ASCII-lex order over
Self::label) whose per-target count equals BOTH
Self::max_variant_count AND Self::min_variant_count
simultaneously (equivalently, whose count sits at the flat-
diagonal collapse where max == min), or None when items
is empty OR the histogram is non-flat (max != min pins a
strict direction split, so NO variant hits both extremes). The
LEX-ORDER peer of Self::bimodal_variant one ORDERING axis
over, CLOSING the (set-level × Option<Self> × statistical-
aggregate × direction-composition × intersection × ordering)
2-corner face at its lex-arm past the declaration-arm the
sibling Self::bimodal_variant opened AND CLOSING the (set-
level × Option<Self> × direction-composition × combinator ×
ordering) 3×2 grid at its FINAL sixth tile past the (union
declaration, union lex, complement declaration, complement lex,
intersection declaration) 5-tile prefix the sibling projections
(Self::extremal_variant, Self::sorted_extremal_variant,
Self::middle_band_variant, Self::sorted_middle_band_variant,
Self::bimodal_variant) covered. Not a fresh substrate
primitive on the index axis — the projection emerges from the
SAME uniformity-collapse SHARPENING as Self::bimodal_variant
(if items.is_empty() || !T::is_uniform(items) { None } else { T::sorted_variants().first().copied() }) with
T::sorted_variants().first().copied() in place of
T::ALL.first().copied() on the uniform arm — the lex axis
surfaces ONLY in the returned first-witness pick. Read moreSource§fn has_unique_middle_band_variant(items: &[Self]) -> bool
fn has_unique_middle_band_variant(items: &[Self]) -> bool
true iff EXACTLY ONE
variant of Self::ALL carries an occurrence-count STRICTLY
between Self::min_variant_count and
Self::max_variant_count, computed as the strict-equality test
of the just-lifted Self::count_middle_band_variants
cardinality-count aggregate against the scalar threshold 1. The
BOOL-RETURN UNIQUE-TIE SHARPENING OPENER on the (set-level × bool
× statistical-aggregate × direction-composition × complement ×
unique-tie) corner OPENING the (set-level × bool × direction-
composition × unique-tie) column past the direction-anchored
(has_unique_mode, has_unique_antimode) argmax/argmin pair one
DIRECTION-COMPOSITION axis over on the modal-aggregation matrix
AND peer to Self::count_middle_band_variants one RETURN-SHAPE
axis over (set-level × usize cardinality → set-level × bool
uniqueness test against 1) AND peer to
Self::has_middle_band_variant one UNIQUE-TIE-SHARPENING axis
over (existential >= 1 → uniqueness == 1). Not a fresh
substrate primitive on the index axis — the predicate emerges
from one strict-equality test of the just-lifted
Self::count_middle_band_variants scalar against 1,
equivalently the Vec::len equality of the declaration-order
middle-band witness-collection Self::middle_band_variants
against 1. Read moreSource§fn has_unique_extremal_variant(items: &[Self]) -> bool
fn has_unique_extremal_variant(items: &[Self]) -> bool
true iff EXACTLY ONE
variant of Self::ALL carries an occurrence-count MATCHING
EITHER Self::max_variant_count OR Self::min_variant_count,
computed as the strict-equality test of the just-lifted
Self::count_extremal_variants cardinality-count aggregate
against the scalar threshold 1. The BOOL-RETURN UNIQUE-TIE
SHARPENING corner CLOSING the (set-level × bool × direction-
composition × unique-tie) row past the just-opened
Self::has_unique_middle_band_variant complement arm one
COMBINATOR axis over on the modal-aggregation matrix AND peer to
Self::count_extremal_variants one RETURN-SHAPE axis over
(set-level × usize cardinality → set-level × bool uniqueness
test against 1) AND peer to Self::has_extremal_variant one
UNIQUE-TIE-SHARPENING axis over (existential >= 1 → uniqueness
== 1). Not a fresh substrate primitive on the index axis — the
predicate emerges from one strict-equality test of the just-lifted
Self::count_extremal_variants scalar against 1, equivalently
the Vec::len equality of the declaration-order union witness-
collection Self::extremal_variants against 1. Read moreSource§fn has_unique_bimodal_variant(items: &[Self]) -> bool
fn has_unique_bimodal_variant(items: &[Self]) -> bool
true iff
EXACTLY ONE variant of Self::ALL carries an occurrence-count
MATCHING BOTH Self::max_variant_count AND
Self::min_variant_count, computed as the strict-equality test
of the just-lifted Self::count_bimodal_variants cardinality-
count aggregate against the scalar threshold 1. The BOOL-RETURN
UNIQUE-TIE SHARPENING corner CLOSING the (set-level × bool ×
direction-composition × unique-tie) row past the just-lifted
Self::has_unique_extremal_variant union arm one COMBINATOR
axis over on the modal-aggregation matrix AND EXHAUSTIVELY
CLOSING the (set-level × bool × direction-composition ×
combinator × unique-tie) row at its FINAL THIRD tile (past the
UNION arm Self::has_unique_extremal_variant closed and the
COMPLEMENT arm Self::has_unique_middle_band_variant closed).
Peer to Self::count_bimodal_variants one RETURN-SHAPE axis
over (set-level × usize cardinality → set-level × bool
uniqueness test against 1) AND peer to
Self::has_bimodal_variant one UNIQUE-TIE-SHARPENING axis
over (existential >= 1 → uniqueness == 1). Not a fresh
substrate primitive on the index axis — the predicate emerges
from one strict-equality test of the just-lifted
Self::count_bimodal_variants scalar against 1,
equivalently the Vec::len equality of the declaration-order
intersection witness-collection Self::bimodal_variants
against 1. Read moreSource§fn unique_extremal_variant(items: &[Self]) -> Option<Self>
fn unique_extremal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE extremal witness
(Self::has_unique_extremal_variant holds) AND v is the sole
variant achieving EITHER Self::max_variant_count OR
Self::min_variant_count, else None. Computed as the just-
lifted set-level extremal-union uniqueness bit
Self::has_unique_extremal_variant guarding the declaration-
order union first-witness Self::extremal_variant projection:
when the guard holds the union witness is unambiguous and lifted
verbatim; when the guard falsifies the projection collapses to
None. The Option<Self>-RETURN UNIQUE-TIE SHARPENING corner
OPENING the (set-level × Option<Self> × statistical-aggregate ×
direction-composition × unique-tie) column past the four unsharpened
(declaration/lex × union/complement/intersection) direction-
composition first-witness peers (Self::extremal_variant,
Self::sorted_extremal_variant, Self::middle_band_variant,
Self::sorted_middle_band_variant, Self::bimodal_variant,
Self::sorted_bimodal_variant) one UNIQUE-TIE-SHARPENING axis
over on the modal-aggregation matrix, AND peer to
Self::unique_modal_variant one DIRECTION-COMPOSITION axis over
(argmax first-witness-if-unique → union first-witness-if-unique)
AND peer to Self::has_unique_extremal_variant one RETURN-SHAPE
axis over (set-level × bool union uniqueness bit → set-level ×
Option<Self> union witness-when-unique). Not a fresh substrate
primitive on the index axis — the projection emerges from a boolean
conjunction of the just-lifted set-level extremal-union uniqueness
bit with the just-lifted declaration-order union first-witness
projection under an Option-collapse when the guard falsifies. Read moreSource§fn unique_middle_band_variant(items: &[Self]) -> Option<Self>
fn unique_middle_band_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE strict-interior
witness (Self::has_unique_middle_band_variant holds) AND v is
the sole variant with occurrence-count STRICTLY BETWEEN
Self::max_variant_count AND Self::min_variant_count, else
None. Computed as the just-lifted set-level middle-band uniqueness
bit Self::has_unique_middle_band_variant guarding the
declaration-order strict-interior first-witness
Self::middle_band_variant projection: when the guard holds the
complement witness is unambiguous and lifted verbatim; when the
guard falsifies the projection collapses to None. The
Option<Self>-RETURN UNIQUE-TIE SHARPENING corner CLOSING the
complement arm of the (set-level × Option<Self> × direction-
composition × unique-tie) row past the just-opened UNION arm
Self::unique_extremal_variant one COMBINATOR axis over on the
modal-aggregation matrix AND peer to
Self::has_unique_middle_band_variant one RETURN-SHAPE axis over
(set-level × bool complement uniqueness bit → set-level ×
Option<Self> complement witness-when-unique) AND peer to
Self::middle_band_variant one UNIQUE-TIE-SHARPENING axis over
(unsharpened declaration-order strict-interior first-witness →
uniqueness-gated declaration-order strict-interior first-witness).
Not a fresh substrate primitive on the index axis — the projection
emerges from a boolean conjunction of the just-lifted set-level
middle-band uniqueness bit with the just-lifted declaration-order
strict-interior first-witness projection under an Option-collapse
when the guard falsifies. Read moreSource§fn unique_bimodal_variant(items: &[Self]) -> Option<Self>
fn unique_bimodal_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE flat-diagonal witness
(Self::has_unique_bimodal_variant holds) AND v is the sole
variant with occurrence-count sitting SIMULTANEOUSLY at BOTH
Self::max_variant_count AND Self::min_variant_count (the
uniformity-collapse max == min fixpoint), else None. Computed
as the just-lifted set-level bimodal uniqueness bit
Self::has_unique_bimodal_variant guarding the declaration-order
intersection first-witness Self::bimodal_variant projection:
when the guard holds the intersection witness is unambiguous and
lifted verbatim; when the guard falsifies the projection collapses
to None. The Option<Self>-RETURN UNIQUE-TIE SHARPENING corner
CLOSING the intersection arm of the (set-level × Option<Self> ×
direction-composition × unique-tie) row past the just-opened UNION
arm Self::unique_extremal_variant AND the just-closed COMPLEMENT
arm Self::unique_middle_band_variant one COMBINATOR axis over
on the modal-aggregation matrix AND EXHAUSTIVELY CLOSING the
(Option<Self> × direction-composition × combinator × unique-tie)
3-corner row at its FINAL THIRD tile past the union + complement
arms AND peer to Self::has_unique_bimodal_variant one
RETURN-SHAPE axis over (set-level × bool intersection uniqueness
bit → set-level × Option<Self> intersection witness-when-unique)
AND peer to Self::bimodal_variant one UNIQUE-TIE-SHARPENING
axis over (unsharpened declaration-order intersection first-witness
→ uniqueness-gated declaration-order intersection first-witness).
Not a fresh substrate primitive on the index axis — the projection
emerges from a boolean conjunction of the just-lifted set-level
bimodal uniqueness bit with the declaration-order intersection
first-witness projection under an Option-collapse when the guard
falsifies. Read moreSource§fn unique_extremal_variants(items: &[Self]) -> Vec<Self>
fn unique_extremal_variants(items: &[Self]) -> Vec<Self>
vec![v] iff items
has a UNIQUE extremal witness (Self::has_unique_extremal_variant
holds) AND v is the sole variant achieving EITHER
Self::max_variant_count OR Self::min_variant_count, else
vec![]. Computed as the just-lifted set-level extremal-union
uniqueness bit Self::has_unique_extremal_variant guarding the
declaration-order union witness-collection
Self::extremal_variants: when the guard holds the collection is
already a length-1 Vec by the guard’s own definition
(count_extremal_variants == 1) and is lifted verbatim; when the
guard falsifies the projection collapses to the EMPTY Vec through
a zero-allocation ::std::vec::Vec::new() short-circuit. The
Vec<Self>-RETURN UNIQUE-TIE SHARPENING corner OPENING the
(set-level × Vec<Self> × statistical-aggregate × direction-
composition × unique-tie) column past the six unsharpened
(declaration/lex × union/complement/intersection) direction-
composition witness-collection peers
(Self::extremal_variants, Self::sorted_extremal_variants,
Self::middle_band_variants,
Self::sorted_middle_band_variants, Self::bimodal_variants,
Self::sorted_bimodal_variants) one UNIQUE-TIE-SHARPENING axis
over on the modal-aggregation matrix AND peer to
Self::unique_extremal_variant (set-level × Option<Self> ×
union × unique-tie) one RETURN-SHAPE axis over (Option-return
witness-when-unique → Vec-return singleton-or-empty-when-unique)
AND peer to Self::has_unique_extremal_variant (set-level ×
bool × union × unique-tie) one RETURN-SHAPE axis over (bool
uniqueness bit → Vec-return singleton-or-empty carrier of the same
bit). Not a fresh substrate primitive on the index axis — the
projection emerges from the boolean-guarded selection of the just-
lifted declaration-order union witness-collection under the set-
level extremal-union uniqueness bit, collapsing to the empty Vec
through the guard-arm when the bit falsifies. Read moreSource§fn unique_middle_band_variants(items: &[Self]) -> Vec<Self>
fn unique_middle_band_variants(items: &[Self]) -> Vec<Self>
vec![v] iff items
has a UNIQUE strict-interior witness (Self::has_unique_middle_band_variant
holds) AND v is the sole variant whose per-target multiplicity
sits STRICTLY between Self::max_variant_count and
Self::min_variant_count, else vec![]. Computed as the just-
lifted set-level middle-band uniqueness bit
Self::has_unique_middle_band_variant guarding the declaration-
order complement witness-collection Self::middle_band_variants:
when the guard holds the collection is already a length-1 Vec by
the guard’s own definition (count_middle_band_variants == 1) and
is lifted verbatim; when the guard falsifies the projection
collapses to the EMPTY Vec through a zero-allocation
::std::vec::Vec::new() short-circuit. The Vec<Self>-RETURN
UNIQUE-TIE SHARPENING corner CLOSING the complement arm of the
(set-level × Vec<Self> × statistical-aggregate × direction-
composition × combinator × unique-tie) row past the just-opened
UNION arm Self::unique_extremal_variants one COMBINATOR axis
over on the modal-aggregation matrix, peer to
Self::unique_middle_band_variant (set-level × Option<Self> ×
complement × unique-tie) one RETURN-SHAPE axis over (Option-return
witness-when-unique → Vec-return singleton-or-empty-when-unique)
AND peer to Self::has_unique_middle_band_variant (set-level ×
bool × complement × unique-tie) one RETURN-SHAPE axis over (bool
uniqueness bit → Vec-return singleton-or-empty carrier of the same
bit). Not a fresh substrate primitive on the index axis — the
projection emerges from the boolean-guarded selection of the just-
lifted declaration-order complement witness-collection under the
set-level middle-band uniqueness bit, collapsing to the empty Vec
through the guard-arm when the bit falsifies. Read moreSource§fn unique_bimodal_variants(items: &[Self]) -> Vec<Self>
fn unique_bimodal_variants(items: &[Self]) -> Vec<Self>
Self::bimodal_variants iff items has a UNIQUE intersection-band
witness (Self::has_unique_bimodal_variant holds — equivalently
the histogram is flat AND T::CARDINALITY == 1), else vec![].
Computed as the just-lifted set-level intersection-band uniqueness
bit Self::has_unique_bimodal_variant guarding the declaration-
order intersection witness-collection Self::bimodal_variants:
when the guard holds the collection is already a length-1 Vec by
the guard’s own definition (count_bimodal_variants == 1) and is
lifted verbatim; when the guard falsifies the projection collapses
to the EMPTY Vec through a zero-allocation
::std::vec::Vec::new() short-circuit. The Vec<Self>-RETURN
UNIQUE-TIE SHARPENING corner CLOSING the intersection arm of the
(set-level × Vec<Self> × statistical-aggregate × direction-
composition × combinator × unique-tie) row past the just-opened
UNION arm Self::unique_extremal_variants AND the just-closed
COMPLEMENT arm Self::unique_middle_band_variants one COMBINATOR
axis over on the modal-aggregation matrix AND EXHAUSTIVELY CLOSING
the (Vec<Self> × direction-composition × combinator × unique-tie)
3-corner row at its FINAL THIRD tile, peer to
Self::unique_bimodal_variant (set-level × Option<Self> ×
intersection × unique-tie) one RETURN-SHAPE axis over (Option-
return witness-when-unique → Vec-return singleton-or-empty-when-
unique) AND peer to Self::has_unique_bimodal_variant
(set-level × bool × intersection × unique-tie) one RETURN-SHAPE
axis over (bool uniqueness bit → Vec-return singleton-or-empty
carrier of the same bit). Not a fresh substrate primitive on the
index axis — the projection emerges from the boolean-guarded
selection of the just-lifted declaration-order intersection
witness-collection under the set-level intersection-band uniqueness
bit, collapsing to the empty Vec through the guard-arm when the
bit falsifies. Read moreSource§fn sorted_unique_extremal_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_extremal_variants(items: &[Self]) -> Vec<Self>
Self::sorted_extremal_variants iff items has a UNIQUE extremum
(Self::has_unique_extremal_variant holds), else vec![].
Computed as the just-lifted set-level extremal uniqueness bit
Self::has_unique_extremal_variant guarding the LEX-ORDER union
witness-collection Self::sorted_extremal_variants: when the guard
holds the collection is already a length-1 Vec by the guard’s own
definition (count_extremal_variants == 1) and is lifted verbatim;
when the guard falsifies the projection collapses to the EMPTY Vec
through a zero-allocation ::std::vec::Vec::new() short-circuit.
The LEX-ORDER Vec<Self>-RETURN UNIQUE-TIE SHARPENING corner
OPENING the LEX-ORDER (Vec<Self> × direction-composition ×
combinator × unique-tie) row past the just-closed declaration-order
trio (Self::unique_extremal_variants,
Self::unique_middle_band_variants,
Self::unique_bimodal_variants) one ORDERING axis over on the
modal-aggregation matrix, peer to Self::unique_extremal_variants
one ORDERING axis over (declaration-order → lex-order union
witness-collection-when-unique) AND peer to
Self::sorted_extremal_variants one UNIQUE-TIE-SHARPENING axis
over (unsharpened lex-order union witness-collection →
uniqueness-gated lex-order union witness-collection) AND peer to
Self::sorted_unique_extremal_variant one RETURN-SHAPE axis over
(Option-return lex-first-witness-when-unique → Vec-return
singleton-or-empty-when-unique). Not a fresh substrate primitive on
the index axis — the projection emerges from the boolean-guarded
selection of the just-lifted lex-order union witness-collection
under the set-level extremal uniqueness bit, collapsing to the
empty Vec through the guard-arm when the bit falsifies. Read moreSource§fn sorted_unique_middle_band_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_middle_band_variants(items: &[Self]) -> Vec<Self>
Self::sorted_middle_band_variants iff items has a UNIQUE strict-
interior variant (Self::has_unique_middle_band_variant holds), else
vec![]. Computed as the just-lifted set-level middle-band uniqueness
bit Self::has_unique_middle_band_variant guarding the LEX-ORDER
complement witness-collection Self::sorted_middle_band_variants:
when the guard holds the collection is already a length-1 Vec by the
guard’s own definition (count_middle_band_variants == 1) and is
lifted verbatim; when the guard falsifies the projection collapses to
the EMPTY Vec through a zero-allocation ::std::vec::Vec::new()
short-circuit. The LEX-ORDER Vec<Self>-RETURN COMPLEMENT UNIQUE-TIE
SHARPENING corner CLOSING the complement arm of the LEX-ORDER
(Vec<Self> × direction-composition × combinator × unique-tie) row
past the just-opened union arm Self::sorted_unique_extremal_variants
one COMBINATOR axis over on the modal-aggregation matrix, peer to
Self::unique_middle_band_variants one ORDERING axis over
(declaration-order → lex-order complement witness-collection-when-
unique) AND peer to Self::sorted_middle_band_variants one UNIQUE-
TIE-SHARPENING axis over (unsharpened lex-order complement witness-
collection → uniqueness-gated lex-order complement witness-collection)
AND peer to Self::sorted_unique_middle_band_variant one RETURN-
SHAPE axis over (Option-return lex-first-witness-when-unique → Vec-
return singleton-or-empty-when-unique). Not a fresh substrate primitive
on the index axis — the projection emerges from the boolean-guarded
selection of the just-lifted lex-order complement witness-collection
under the set-level middle-band uniqueness bit, collapsing to the
empty Vec through the guard-arm when the bit falsifies. Read moreSource§fn sorted_unique_bimodal_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_bimodal_variants(items: &[Self]) -> Vec<Self>
Self::sorted_bimodal_variants iff items has a UNIQUE intersection-
band witness (Self::has_unique_bimodal_variant holds — equivalently
the histogram is flat AND T::CARDINALITY == 1), else vec![].
Computed as the just-lifted set-level intersection-band uniqueness bit
Self::has_unique_bimodal_variant guarding the LEX-ORDER intersection
witness-collection Self::sorted_bimodal_variants: when the guard
holds the collection is already a length-1 Vec by the guard’s own
definition (count_bimodal_variants == 1) and is lifted verbatim; when
the guard falsifies the projection collapses to the EMPTY Vec through a
zero-allocation ::std::vec::Vec::new() short-circuit. The LEX-ORDER
Vec<Self>-RETURN INTERSECTION UNIQUE-TIE SHARPENING corner CLOSING
the intersection arm of the LEX-ORDER (Vec<Self> × direction-
composition × combinator × unique-tie) row past the just-opened UNION
arm Self::sorted_unique_extremal_variants AND the just-closed
COMPLEMENT arm Self::sorted_unique_middle_band_variants one
COMBINATOR axis over on the modal-aggregation matrix AND EXHAUSTIVELY
CLOSING the (set-level × Vec<Self> × direction-composition ×
combinator × ordering × unique-tie) 3×2 face at its FINAL SIXTH TILE,
peer to Self::unique_bimodal_variants one ORDERING axis over
(declaration-order → lex-order intersection witness-collection-when-
unique) AND peer to Self::sorted_bimodal_variants one UNIQUE-TIE-
SHARPENING axis over (unsharpened lex-order intersection witness-
collection → uniqueness-gated lex-order intersection witness-
collection) AND peer to Self::sorted_unique_bimodal_variant one
RETURN-SHAPE axis over (Option-return lex-first-witness-when-unique →
Vec-return singleton-or-empty-when-unique). Not a fresh substrate
primitive on the index axis — the projection emerges from the boolean-
guarded selection of the just-lifted lex-order intersection witness-
collection under the set-level intersection-band uniqueness bit,
collapsing to the empty Vec through the guard-arm when the bit
falsifies. Read moreSource§fn is_unique_extremal_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_extremal_variant_of(target: Self, items: &[Self]) -> bool
true iff target is an extremal variant of
items (its per-target multiplicity sits on the union of the argmax
and argmin bands via Self::is_extremal_variant_of) AND items
has a unique extremum (Self::count_extremal_variants == 1),
computed as the conjunction of the per-target union membership
predicate Self::is_extremal_variant_of with the set-level
extremal-uniqueness predicate Self::has_unique_extremal_variant.
The BOOL-RETURN PER-TARGET UNION UNIQUE-TIE SHARPENING corner
OPENING the (per-target × bool × statistical-aggregate × direction-
composition × union × unique-tie) column past the direction-anchored
(is_unique_modal_variant_of, is_unique_antimodal_variant_of) pair
one DIRECTION-COMPOSITION axis over on the modal-aggregation matrix
AND peer to Self::has_unique_extremal_variant (set-level × bool
× union × unique-tie) one ARITY axis over AND peer to
Self::is_extremal_variant_of (per-target × bool × union) one
UNIQUE-TIE-SHARPENING axis over AND peer to
Self::unique_extremal_variant (set-level × Option<Self> ×
union × unique-tie) one ARITY axis over. Not a fresh substrate
primitive on the index axis — the predicate emerges from the
conjunction of the just-lifted per-target union membership predicate
with the just-lifted set-level extremal-uniqueness scalar,
equivalently the strict-equality test of the just-lifted first-
witness Self::unique_extremal_variant projection against
Some(target). Read moreSource§fn is_unique_middle_band_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_middle_band_variant_of(target: Self, items: &[Self]) -> bool
target the SOLE
strictly-interior variant?” predicate — true iff target
sits STRICTLY BETWEEN the max and min counts of items AND
exactly ONE variant of Self::ALL sits on that strict-
interior band, computed as the just-lifted per-target
complement membership Self::is_middle_band_variant_of
projection conjoined with the just-lifted set-level
complement uniqueness bit
Self::has_unique_middle_band_variant via &&. The
(per-target × bool × direction-composition × complement ×
unique-tie) corner CLOSING the complement arm of the (per-
target × bool × direction-composition × combinator × unique-
tie) 3-corner row past the just-opened union arm
Self::is_unique_extremal_variant_of one COMBINATOR axis
over. Read moreSource§fn is_unique_bimodal_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_bimodal_variant_of(target: Self, items: &[Self]) -> bool
target the SOLE
flat-diagonal variant?” predicate — true iff target sits on
BOTH the argmax AND the argmin bands of items
simultaneously AND exactly ONE variant of Self::ALL sits on
that intersection band, computed as the just-lifted per-target
intersection membership Self::is_bimodal_variant_of
projection conjoined with the just-lifted set-level
intersection uniqueness bit
Self::has_unique_bimodal_variant via &&. The (per-target ×
bool × direction-composition × intersection × unique-tie)
corner CLOSING the intersection arm of the (per-target × bool ×
direction-composition × combinator × unique-tie) 3-corner row
past the just-opened union arm
Self::is_unique_extremal_variant_of AND the just-closed
complement arm Self::is_unique_middle_band_variant_of one
COMBINATOR axis over AND EXHAUSTIVELY CLOSING the (per-target ×
bool × direction-composition × combinator × unique-tie)
3-corner row at its FINAL THIRD tile. Read moreSource§fn is_repeating_any(items: &[Self]) -> bool
fn is_repeating_any(items: &[Self]) -> bool
true iff AT LEAST ONE variant of Self::ALL appears TWO OR
MORE times in items, computed as the just-lifted usize-return
Self::max_variant_count projection MEETING-OR-EXCEEDING the
scalar threshold 2. The BOOL-RETURN opener on the (set-level ×
bool × multiplicity-band >= 2) corner peer to the (set-level ×
bool × multiplicity-band == 0) Self::is_missing_any corner
one MULTIPLICITY-BAND axis over, AND the direct SET-LEVEL
EXISTENTIAL LIFT of the (per-target × bool × multiplicity-band
>= 2) Self::is_repeated_occurrence_of corner one ARITY axis
over on the (arity × mult-band) face of the equivalence-partition
surface. Not a fresh substrate primitive on the index axis — the
predicate emerges from one comparison of the just-lifted
Self::max_variant_count modal-count aggregate against 2,
equivalently the disjunction over Self::ALL of the per-target
Self::is_repeated_occurrence_of predicate. Read moreSource§fn is_unique_any(items: &[Self]) -> bool
fn is_unique_any(items: &[Self]) -> bool
true iff AT LEAST ONE variant of Self::ALL appears EXACTLY
ONCE in items, computed as the disjunction over Self::ALL
of the per-target Self::is_unique_occurrence_of predicate.
The BOOL-RETURN closer on the (set-level × bool × multiplicity-
band) 3-corner existential-lift face at its final == 1
corner peer to the (set-level × bool × multiplicity-band == 0)
Self::is_missing_any corner and the (set-level × bool ×
multiplicity-band >= 2) Self::is_repeating_any corner
one MULTIPLICITY-BAND axis over, AND the direct SET-LEVEL
EXISTENTIAL LIFT of the (per-target × bool × multiplicity-band
== 1) Self::is_unique_occurrence_of corner one ARITY
axis over on the (arity × mult-band) face of the equivalence-
partition surface. Not a fresh substrate primitive on the
index axis — the predicate emerges from one existential
disjunction over Self::ALL of the per-target multiplicity-
== 1 predicate, equivalently the histogram vector’s
containment of the scalar 1. Read moreSource§fn count_unique_variants(items: &[Self]) -> usize
fn count_unique_variants(items: &[Self]) -> usize
usize count of variants of
Self::ALL whose per-target multiplicity in items equals
EXACTLY 1, computed as the .count() reduction of
Self::ALL filtered through the per-target
Self::is_unique_occurrence_of predicate. The SET-LEVEL
USIZE-RETURN closer on the (set-level × usize × multiplicity-
band) 3-corner face at the middle band peer to the (set-level
× usize × multiplicity-band == 0) Self::count_missing
corner one MULTIPLICITY-BAND axis over, AND the direct
USIZE-RETURN SHARPENING of the (set-level × bool ×
multiplicity-band == 1) Self::is_unique_any corner one
return-shape axis over — while Self::is_unique_any reports
“IS THERE at least one variant occurring exactly once?” (a
set-level bool), this projection reports “HOW MANY variants
occur exactly once?” (a set-level usize that is a strict
refinement of the bool). Not a fresh substrate primitive on
the index axis — the count emerges from one composition of
Self::ALL filtered through the per-target
Self::is_unique_occurrence_of uniqueness primitive. Read moreSource§fn count_repeating_variants(items: &[Self]) -> usize
fn count_repeating_variants(items: &[Self]) -> usize
usize
SET-LEVEL count of variants of Self::ALL whose per-target
multiplicity in items is STRICTLY AT LEAST 2, computed as
the filter-count reduction over Self::ALL of the per-target
Self::is_repeated_occurrence_of predicate. The USIZE-RETURN
closer on the (set-level × usize × multiplicity-band) 3-corner
cardinality-count face at its final >= 2 strict-repeat
corner peer to the (set-level × usize × multiplicity-band
== 0) Self::count_missing corner and the (set-level ×
usize × multiplicity-band == 1) Self::count_unique_variants
corner one MULTIPLICITY-BAND axis over, AND the direct SET-
LEVEL EXISTENTIAL-COUNT SHARPENING of the (set-level × bool ×
multiplicity-band >= 2) Self::is_repeating_any predicate
one return-shape axis over (bool-return → usize-return via
cardinality sharpening) on the (arity × mult-band × return-
shape) face of the equivalence-partition surface. Not a fresh
substrate primitive on the index axis — the count emerges from
one filter-count reduction over Self::ALL of the per-target
multiplicity->= 2 predicate, equivalently the count of per-
slot histogram bars strictly at least 2. Read moreSource§fn has_unique_repeating_variant(items: &[Self]) -> bool
fn has_unique_repeating_variant(items: &[Self]) -> bool
true iff EXACTLY ONE
variant of Self::ALL carries an occurrence-count STRICTLY AT
LEAST 2 in items, computed as the strict-equality test of the
just-lifted Self::count_repeating_variants cardinality-count
aggregate against the scalar threshold 1. The BOOL-RETURN
UNIQUE-TIE SHARPENING corner OPENING the (set-level × bool ×
equivalence-partition × multiplicity-band × unique-tie) row on the
EQUIVALENCE-PARTITION surface at its (mult >= 2) band, peer to
Self::count_repeating_variants one RETURN-SHAPE axis over
(set-level × usize cardinality → set-level × bool uniqueness
test against 1), peer to Self::is_repeating_any one UNIQUE-
TIE-SHARPENING axis over (existential >= 1 → uniqueness == 1)
AND peer to Self::has_unique_extremal_variant +
Self::has_unique_middle_band_variant +
Self::has_unique_bimodal_variant one SURFACE axis over — those
three land the same unique-tie sharpening on the modal-
AGGREGATION surface (direction-composition × combinator); THIS
projection lands it on the equivalence-PARTITION surface
(multiplicity-band). Not a fresh substrate primitive on the index
axis — the predicate emerges from one strict-equality test of the
just-lifted Self::count_repeating_variants scalar against 1,
equivalently the Vec::len equality of the declaration-order
strict-repeat witness-collection Self::repeating_variants
against 1. Read moreSource§fn unique_repeating_variant(items: &[Self]) -> Option<Self>
fn unique_repeating_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE strict-repeat
witness (Self::has_unique_repeating_variant holds) AND v is
the sole variant whose per-target multiplicity in items sits
STRICTLY AT LEAST 2 (equivalently, the sole variant on
Self::ALL satisfying Self::is_repeated_occurrence_of at
this slice), else None. Computed as the just-lifted set-level
strict-repeat uniqueness bit Self::has_unique_repeating_variant
guarding a declaration-order first-witness sweep of Self::ALL
through the substrate’s per-target strict-repeat primitive
Self::is_repeated_occurrence_of: when the guard holds the
sweep hits EXACTLY ONE variant and the sole witness lifts through
verbatim; when the guard falsifies the projection collapses to
None. The Option<Self>-RETURN UNIQUE-TIE SHARPENING corner
OPENING the (set-level × Option<Self> × equivalence-partition ×
multiplicity-band >= 2 × unique-tie) column past the just-
lifted Self::has_unique_repeating_variant one RETURN-SHAPE
axis over (set-level × bool strict-repeat uniqueness bit →
set-level × Option<Self> strict-repeat witness-when-unique) AND
peer to Self::unique_extremal_variant +
Self::unique_middle_band_variant +
Self::unique_bimodal_variant one SURFACE axis over — those
three land the same Option<Self> uniqueness-guarded witness on
the MODAL-AGGREGATION surface (direction-composition × combinator);
THIS projection lands it on the EQUIVALENCE-PARTITION surface
(multiplicity-band). Not a fresh substrate primitive on the index
axis — the projection emerges from the just-lifted set-level
strict-repeat uniqueness bit guarding a first-witness sweep of
Self::ALL through the substrate’s per-target strict-repeat
primitive under an Option-collapse when the guard falsifies. Read moreSource§fn is_unique_repeating_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_repeating_variant_of(target: Self, items: &[Self]) -> bool
target the SOLE
strictly-repeating variant?” predicate — true iff target
occurs TWO OR MORE times in items AND exactly ONE variant of
Self::ALL sits on that strict-repeat band, computed as the
substrate’s per-target strict-repeat membership
Self::is_repeated_occurrence_of projection conjoined with
the just-lifted set-level strict-repeat uniqueness bit
Self::has_unique_repeating_variant via &&. The (per-
target × bool × equivalence-partition × multiplicity-band
>= 2 × unique-tie sharpening) corner OPENING the equivalence-
partition arm of the (per-target × bool × unique-tie) column
peer to Self::is_unique_extremal_variant_of +
Self::is_unique_middle_band_variant_of +
Self::is_unique_bimodal_variant_of one SURFACE axis over —
those three land the same bool uniqueness-guarded predicate
on the MODAL-AGGREGATION surface (direction-composition ×
combinator); THIS projection lands it on the EQUIVALENCE-
PARTITION surface (multiplicity-band). AND peer to
Self::has_unique_repeating_variant one ARITY axis over,
AND peer to Self::unique_repeating_variant one RETURN-
SHAPE axis over. Not a fresh substrate primitive on the index
axis — the predicate emerges from the boolean conjunction of
the substrate’s per-target strict-repeat primitive with the
just-lifted set-level strict-repeat uniqueness bit. Read moreSource§fn has_unique_missing_variant(items: &[Self]) -> bool
fn has_unique_missing_variant(items: &[Self]) -> bool
== 0) MISS-band
fall on a UNIQUE variant?” set-level predicate — true iff
EXACTLY ONE variant of Self::ALL is ABSENT from items
(i.e., items hits every variant except one), computed as
the strict-equality test of Self::count_missing against
the scalar threshold 1. The BOOL-RETURN UNIQUE-TIE
SHARPENING corner CLOSING the miss-band arm of the (set-
level × bool × equivalence-partition × multiplicity-band ×
unique-tie) row on the EQUIVALENCE-PARTITION surface at its
(mult == 0) band, peer to Self::has_unique_repeating_variant
(mult >= 2) one MULTIPLICITY-BAND axis over — the two
together bracket the unique-tie sharpening at BOTH extremal
bands of the mult-band trichotomy; peer to
Self::count_missing one RETURN-SHAPE axis over (set-
level × usize miss-cardinality → set-level × bool miss-
uniqueness test against 1); peer to Self::is_missing_any
one UNIQUE-TIE-SHARPENING axis over (existential >= 1 →
uniqueness == 1). Not a fresh substrate primitive on the
index axis — the predicate emerges from one strict-equality
test of the substrate’s Self::count_missing scalar
against 1, equivalently the Vec::len equality of the
declaration-order miss witness-collection
Self::missing_variants against 1. Read moreSource§fn has_unique_unique_variant(items: &[Self]) -> bool
fn has_unique_unique_variant(items: &[Self]) -> bool
== 1) UNIQUE-band
fall on a UNIQUE variant?” set-level predicate — true iff
EXACTLY ONE variant of Self::ALL occurs at multiplicity
EXACTLY 1 in items (i.e., items has EXACTLY ONE
singleton-multiplicity witness on its per-variant histogram),
computed as the strict-equality test of
Self::count_unique_variants against the scalar threshold
1. The BOOL-RETURN UNIQUE-TIE SHARPENING corner
EXHAUSTIVELY CLOSING the middle-band arm of the (set-level ×
bool × equivalence-partition × multiplicity-band × unique-
tie) row on the EQUIVALENCE-PARTITION surface at its
(mult == 1) band — the row’s FINAL THIRD tile past the
just-lifted (mult == 0) Self::has_unique_missing_variant
miss-band arm and the (mult >= 2)
Self::has_unique_repeating_variant strict-repeat arm one
MULTIPLICITY-BAND axis over. The three together bracket the
unique-tie sharpening across ALL THREE bands of the mult-
band trichotomy (== 0, == 1, >= 2), exhaustively
closing the (set-level × bool × equivalence-partition ×
mult-band × unique-tie) 3-corner row on the equivalence-
partition surface — the mirror closure of the (set-level ×
usize × equivalence-partition × mult-band) 3-corner
cardinality-count row (Self::count_missing,
Self::count_unique_variants,
Self::count_repeating_variants) one RETURN-SHAPE axis
over on the equivalence-partition surface, AND the mirror
closure of the (set-level × bool × equivalence-partition ×
mult-band × existential) 3-corner existential-lift row
(Self::is_missing_any, Self::is_unique_any,
Self::is_repeating_any) one UNIQUE-TIE-SHARPENING axis
over. Peer to Self::count_unique_variants one RETURN-
SHAPE axis over (set-level × usize unique-cardinality →
set-level × bool unique-uniqueness test against 1); peer
to Self::is_unique_any one UNIQUE-TIE-SHARPENING axis
over (existential >= 1 → uniqueness == 1). Not a fresh
substrate primitive on the index axis — the predicate emerges
from one strict-equality test of the substrate’s
Self::count_unique_variants scalar against 1,
equivalently the count of per-variant histogram bars strictly
equal to 1 collapsed to a == 1 bit. Read moreSource§fn unique_unique_variant(items: &[Self]) -> Option<Self>
fn unique_unique_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE singleton-
multiplicity witness (Self::has_unique_unique_variant holds)
AND v is the sole variant whose per-target multiplicity in
items sits EXACTLY at 1 (equivalently, the sole variant on
Self::ALL satisfying Self::is_unique_occurrence_of at
this slice), else None. Computed as the just-lifted set-level
unique-band uniqueness bit Self::has_unique_unique_variant
guarding a declaration-order first-witness sweep of Self::ALL
through the substrate’s per-target singleton-multiplicity
primitive Self::is_unique_occurrence_of: when the guard holds
the sweep hits EXACTLY ONE variant and the sole witness lifts
through verbatim; when the guard falsifies the projection
collapses to None. The Option<Self>-RETURN UNIQUE-TIE
SHARPENING corner EXHAUSTIVELY CLOSING the middle-band arm of
the (set-level × Option<Self> × equivalence-partition ×
multiplicity-band × unique-tie) row on the EQUIVALENCE-PARTITION
surface at its (mult == 1) band — the row’s FINAL THIRD tile
past the just-lifted (mult >= 2)
Self::unique_repeating_variant strict-repeat arm one
MULTIPLICITY-BAND axis over. Peer to
Self::has_unique_unique_variant one RETURN-SHAPE axis over
(set-level × bool unique-band uniqueness bit → set-level ×
Option<Self> unique-band witness-when-unique); peer to
Self::unique_repeating_variant one MULTIPLICITY-BAND axis
over (mult >= 2 Option<Self> strict-repeat witness → mult
== 1 Option<Self> unique-band witness). Not a fresh
substrate primitive on the index axis — the projection emerges
from the just-lifted set-level unique-band uniqueness bit
guarding a first-witness sweep of Self::ALL through the
substrate’s per-target singleton-multiplicity primitive under
an Option-collapse when the guard falsifies. Read moreSource§fn unique_missing_variant(items: &[Self]) -> Option<Self>
fn unique_missing_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE miss-band witness
(Self::has_unique_missing_variant holds) AND v is the sole
variant of Self::ALL whose per-target multiplicity sits at
== 0, else None. Computed as the just-lifted set-level
miss-band uniqueness bit Self::has_unique_missing_variant
guarding a declaration-order first-witness sweep of Self::ALL
keyed on !<Self as ClosedSet>::occurs_in: when the guard holds
the sweep hits the SOLE missing variant unambiguously; when the
guard falsifies the projection collapses to None. The
Option<Self>-RETURN UNIQUE-TIE SHARPENING corner EXHAUSTIVELY
CLOSING the miss-band arm of the (set-level × Option<Self> ×
equivalence-partition × multiplicity-band × unique-tie) row on
the EQUIVALENCE-PARTITION surface at its (mult == 0) band —
the FINAL THIRD tile past the just-lifted (mult >= 2) peer
Self::unique_repeating_variant and the (mult == 1) peer
Self::unique_unique_variant one MULTIPLICITY-BAND axis over.
Together the three EXHAUSTIVELY CLOSE the (set-level ×
Option<Self> × equivalence-partition × mult-band × unique-tie)
trichotomy row on the equivalence-partition surface — peer to
Self::has_unique_missing_variant one RETURN-SHAPE axis over
(set-level × bool miss-band uniqueness bit → set-level ×
Option<Self> miss-band witness-when-unique) AND peer to
Self::unique_extremal_variant +
Self::unique_middle_band_variant +
Self::unique_bimodal_variant one SURFACE axis over on the
modal-aggregation matrix. Not a fresh substrate primitive on the
index axis — the projection emerges from a boolean conjunction
of the just-lifted set-level miss-band uniqueness bit with a
declaration-order first-witness Iterator::find sweep under
an Option-collapse when the guard falsifies. Read moreSource§fn sorted_unique_missing_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_missing_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE miss-band
witness (Self::has_unique_missing_variant holds) AND v is
the sole variant of Self::sorted_variants whose per-target
multiplicity sits at == 0, else None. Computed as the just-
lifted set-level miss-band uniqueness bit
Self::has_unique_missing_variant guarding a LEX-ORDER first-
witness sweep of Self::sorted_variants keyed on
!<Self as ClosedSet>::occurs_in. The LEX-ORDER Option<Self>-
RETURN UNIQUE-TIE SHARPENING corner OPENING the (set-level ×
Option<Self> × ordering × equivalence-partition ×
multiplicity-band × unique-tie) row on the EQUIVALENCE-PARTITION
surface at its (mult == 0) miss-band arm — the lex-ordering
peer of the just-lifted declaration-order
Self::unique_missing_variant one ORDERING axis over, peer to
Self::sorted_missing_variants one UNIQUE-TIE-SHARPENING axis
over (existential >= 1 Vec of misses → uniqueness == 1
Option<Self> collapse), AND peer to
Self::sorted_extremal_variant +
Self::sorted_middle_band_variant +
Self::sorted_bimodal_variant one SURFACE axis over on the
modal-aggregation matrix. Not a fresh substrate primitive on the
index axis — the projection emerges from a boolean conjunction
of the just-lifted set-level miss-band uniqueness bit with a
lex-order first-witness Iterator::find sweep of
Self::sorted_variants under an Option-collapse when the
guard falsifies. Read moreSource§fn sorted_unique_repeating_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_repeating_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE strict-
repeat witness (Self::has_unique_repeating_variant holds) AND
v is the sole variant of Self::sorted_variants whose per-
target multiplicity sits at >= 2, else None. Computed as the
just-lifted set-level strict-repeat uniqueness bit
Self::has_unique_repeating_variant guarding a LEX-ORDER first-
witness sweep of Self::sorted_variants keyed on
Self::is_repeated_occurrence_of. The LEX-ORDER Option<Self>-
RETURN UNIQUE-TIE SHARPENING corner OPENING the (set-level ×
Option<Self> × sorted × equivalence-partition × multiplicity-band
× unique-tie) row on the EQUIVALENCE-PARTITION surface at its
(mult >= 2) strict-repeat arm — the lex-ordering peer of the
just-closed declaration-order Self::unique_repeating_variant
one ORDERING axis over, peer to
Self::sorted_repeating_variants one UNIQUE-TIE-SHARPENING axis
over (existential >= 1 Vec of strict-repeaters → uniqueness
== 1 Option<Self> collapse), AND peer to
Self::sorted_unique_missing_variant one MULTIPLICITY-BAND axis
over on the equivalence-partition surface (the two together
bracket the LEX-ORDER Option<Self> unique-tie sharpening at BOTH
EXTREMAL bands of the mult-band trichotomy — the mult == 1
middle arm sorted_unique_unique_variant remains the last tile).
Not a fresh substrate primitive on the index axis — the projection
emerges from a boolean conjunction of the set-level strict-repeat
uniqueness bit with a lex-order first-witness Iterator::find
sweep of Self::sorted_variants under an Option-collapse when
the guard falsifies. Read moreSource§fn sorted_unique_unique_variant(items: &[Self]) -> Option<Self>
fn sorted_unique_unique_variant(items: &[Self]) -> Option<Self>
Some(v) iff items has a UNIQUE
singleton-multiplicity witness (Self::has_unique_unique_variant
holds) AND v is the sole variant of Self::sorted_variants
whose per-target multiplicity sits EXACTLY at 1, else None.
Computed as the just-lifted set-level unique-band uniqueness bit
Self::has_unique_unique_variant guarding a LEX-ORDER first-
witness sweep of Self::sorted_variants keyed on the substrate’s
per-target singleton-multiplicity primitive
Self::is_unique_occurrence_of. The LEX-ORDER Option<Self>-
RETURN UNIQUE-TIE SHARPENING corner EXHAUSTIVELY CLOSING the
middle-band arm of the (set-level × Option<Self> × sorted ×
equivalence-partition × multiplicity-band × unique-tie) row on the
EQUIVALENCE-PARTITION surface at its (mult == 1) band — the FINAL
THIRD tile past the just-lifted (mult >= 2)
Self::sorted_unique_repeating_variant strict-repeat arm AND the
just-lifted (mult == 0) Self::sorted_unique_missing_variant
miss-band arm one MULTIPLICITY-BAND axis over. Together the three
EXHAUSTIVELY CLOSE the (set-level × Option<Self> × sorted ×
equivalence-partition × mult-band × unique-tie) trichotomy row on
the LEX-ORDER equivalence-partition surface. Peer to
Self::unique_unique_variant one ORDERING axis over (the
declaration-order sibling this LEX peer is provably identical to),
AND peer to Self::has_unique_unique_variant one RETURN-SHAPE
axis over. Not a fresh substrate primitive on the index axis — the
projection emerges from a boolean-guarded lex-order first-witness
Iterator::find sweep of Self::sorted_variants under an
Option-collapse when the guard falsifies. Read moreSource§fn is_unique_missing_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_missing_variant_of(target: Self, items: &[Self]) -> bool
target the SOLE
absent variant?” predicate — true iff target does NOT
occur in items AND exactly ONE variant of Self::ALL is
missing from items, computed as the negation of the
substrate’s per-target membership predicate
Self::occurs_in conjoined with the just-lifted set-level
miss-band uniqueness bit Self::has_unique_missing_variant
via &&. The (per-target × bool × equivalence-partition ×
multiplicity-band == 0 × unique-tie sharpening) corner
OPENING the miss-band arm of the (per-target × bool ×
equivalence-partition × mult-band × unique-tie) column past
the just-opened (mult >= 2)
Self::is_unique_repeating_variant_of strict-repeat arm one
MULTIPLICITY-BAND axis over on the EQUIVALENCE-PARTITION
surface — the two together bracket the per-target unique-tie
sharpening at BOTH EXTREMAL bands of the mult-band trichotomy.
Peer to Self::has_unique_missing_variant one ARITY axis
over (set-level bool miss-band uniqueness bit → per-target
bool miss-band membership-if-unique test); peer to
Self::unique_missing_variant one RETURN-SHAPE axis over
(set-level Option<Self> miss-band witness-when-unique →
per-target bool miss-band membership-when-unique). Not a
fresh substrate primitive on the index axis — the predicate
emerges from the boolean conjunction of the negation of the
substrate’s per-target membership primitive with the just-
lifted set-level miss-band uniqueness bit. Read moreSource§fn is_unique_unique_variant_of(target: Self, items: &[Self]) -> bool
fn is_unique_unique_variant_of(target: Self, items: &[Self]) -> bool
target the SOLE
singleton-multiplicity variant?” predicate — true iff target
occurs EXACTLY ONCE in items AND exactly ONE variant of
Self::ALL sits on that singleton-multiplicity band, computed
as the substrate’s per-target singleton-multiplicity
Self::is_unique_occurrence_of projection conjoined with the
just-lifted set-level unique-band uniqueness bit
Self::has_unique_unique_variant via &&. The (per-target ×
bool × equivalence-partition × multiplicity-band == 1 ×
unique-tie sharpening) corner EXHAUSTIVELY CLOSING the middle-
band arm of the (per-target × bool × equivalence-partition ×
mult-band × unique-tie) 3-corner row on the EQUIVALENCE-
PARTITION surface at its FINAL third tile past the (mult >= 2)
Self::is_unique_repeating_variant_of strict-repeat arm AND
the (mult == 0) Self::is_unique_missing_variant_of miss-
band arm one MULTIPLICITY-BAND axis over — the three together
EXHAUSTIVELY CLOSE the per-target unique-tie sharpening across
the mult-band trichotomy, mirroring the same exhaustive closure
at the set-level bool (
Self::has_unique_repeating_variant +
Self::has_unique_missing_variant +
Self::has_unique_unique_variant) row and set-level
Option<Self> (Self::unique_repeating_variant +
Self::unique_missing_variant +
Self::unique_unique_variant) row. Peer to
Self::has_unique_unique_variant one ARITY axis over AND peer
to Self::unique_unique_variant one RETURN-SHAPE axis over —
the (bool set-level, Option<Self> set-level, bool per-
target) 3-corner mini-face on the middle-band arm of the
equivalence-partition surface now closes at THIS third corner,
mirroring the same 3-corner closure at the strict-repeat arm
(Self::has_unique_repeating_variant,
Self::unique_repeating_variant,
Self::is_unique_repeating_variant_of) AND at the miss-band
arm (Self::has_unique_missing_variant,
Self::unique_missing_variant,
Self::is_unique_missing_variant_of) one MULTIPLICITY-BAND
axis over. Not a fresh substrate primitive on the index axis —
the predicate emerges from the boolean conjunction of the
substrate’s per-target singleton-multiplicity primitive with the
just-lifted set-level unique-band uniqueness bit. Read moreSource§fn present_variants(items: &[Self]) -> Vec<Self>
fn present_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER hit-set of Self::ALL,
keeping every variant that OCCURS at least once in items
and dropping every variant that does NOT. The VEC-RETURN
PRESENT-ARM opener on the equivalence-partition surface,
positioned as the concrete WITNESS behind the just-lifted
bool-return Self::is_covering predicate (which reports
whether the hit-set reaches full cardinality) and the
usize-return Self::count_distinct projection (which
reports the hit-set’s cardinality alone). Sibling posture to
Self::missing_variants one column of the (partition-arm)
axis over: this projection materializes the PRESENT arm as
a Vec<Self> witness; Self::missing_variants
materializes the ABSENT arm as a Vec<Self> witness. The
(present, absent) × (bool, usize, Vec) 2×3 = 6-corner
partition-arm × return-shape face on the equivalence-
partition surface now opens the Vec-return column at BOTH
partition arms. Read moreSource§fn missing_variants(items: &[Self]) -> Vec<Self>
fn missing_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER miss-set of Self::ALL,
keeping every variant that does NOT occur in items and
dropping every variant that DOES. The VEC-RETURN ABSENT-ARM
closer on the (present, absent) partition-arm axis over the
Vec-return column of the equivalence-partition surface,
positioned as the direct DE MORGAN dual of
Self::present_variants and as the concrete WITNESS
behind the just-lifted bool-return Self::is_missing_any
predicate (which reports whether the miss-set is non-empty)
and the usize-return Self::count_missing projection
(which reports the miss-set’s cardinality alone). Read moreSource§fn repeating_variants(items: &[Self]) -> Vec<Self>
fn repeating_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER strict-repeat set of
Self::ALL, keeping every variant whose per-target
multiplicity in items is >= 2 and dropping every variant
whose multiplicity is <= 1. The VEC-RETURN STRICT-REPEAT
corner OPENING the (Vec<Self>, set-level, multiplicity-
band >= 2) column past the (bool, set-level,
multiplicity-band >= 2) Self::is_repeating_any
existential corner AND the (usize, set-level, multiplicity-
band >= 2) Self::count_repeating_variants cardinality
corner on the equivalence-partition surface, positioned as
the concrete WITNESS behind those two peer projections
(which report whether the strict-repeat set is non-empty and
its cardinality alone, respectively). Read moreSource§fn sorted_present_variants(items: &[Self]) -> Vec<Self>
fn sorted_present_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER hit-set of Self::sorted_variants,
keeping every variant that DOES occur in items and dropping
every variant that doesn’t. The LEX-ORDER peer of
Self::present_variants on the (declaration, lex) ordering
axis of the Vec-return column of the equivalence-partition
surface — opens the lex arm past the declaration arm the prior
pair closed. Read moreSource§fn sorted_missing_variants(items: &[Self]) -> Vec<Self>
fn sorted_missing_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER miss-set of Self::sorted_variants,
keeping every variant that does NOT occur in items and
dropping every variant that DOES. The LEX-ORDER peer of
Self::missing_variants on the (declaration, lex) ordering
axis of the Vec-return column of the equivalence-partition
surface — closes the lex arm past the declaration arm the
sibling Self::sorted_present_variants opened. Read moreSource§fn sorted_repeating_variants(items: &[Self]) -> Vec<Self>
fn sorted_repeating_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER strict-repeat set of
Self::sorted_variants, keeping every variant whose per-
target multiplicity in items is >= 2 and dropping every
variant whose multiplicity is <= 1. The LEX-ORDER peer of
Self::repeating_variants on the (declaration, lex)
ordering axis of the Vec<Self>-return strict-repeat-band
column of the equivalence-partition surface — CLOSES the lex
arm past the declaration arm the sibling
Self::repeating_variants opened, and CLOSES the (partition-
arm × ordering) 3×2 = 6-corner Vec<Self>-return face at its
SIXTH (strict-repeat, lex) corner peer to
Self::sorted_present_variants (present × lex) and
Self::sorted_missing_variants (absent × lex) one PARTITION-
ARM axis over on the same lex column. Read moreSource§fn unique_variants(items: &[Self]) -> Vec<Self>
fn unique_variants(items: &[Self]) -> Vec<Self>
Vec<Self> DECLARATION-ORDER strict-uniqueness set of
Self::ALL, keeping every variant whose per-target
multiplicity in items is EXACTLY 1 and dropping every
variant whose multiplicity is 0 or >= 2. The VEC-RETURN
STRICT-UNIQUENESS corner OPENING the (Vec<Self>, set-level,
multiplicity-band == 1) column past the (bool, set-level,
multiplicity-band == 1) Self::is_unique_any existential
corner AND the (usize, set-level, multiplicity-band == 1)
Self::count_unique_variants cardinality corner on the
equivalence-partition surface, positioned as the concrete
WITNESS behind those two peer projections (which report
whether the strict-uniqueness set is non-empty and its
cardinality alone, respectively). Read moreSource§fn sorted_unique_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_variants(items: &[Self]) -> Vec<Self>
Vec<Self> LEX-ORDER strict-uniqueness set of
Self::sorted_variants, keeping every variant whose per-
target multiplicity in items is EXACTLY 1 and dropping
every variant whose multiplicity is 0 or >= 2. The LEX-
ORDER peer of Self::unique_variants on the (declaration,
lex) ordering axis of the Vec-return column of the
equivalence-partition surface — closes the lex arm past the
declaration arm the prior projection opens. Read moreSource§fn unique_missing_variants(items: &[Self]) -> Vec<Self>
fn unique_missing_variants(items: &[Self]) -> Vec<Self>
Self::missing_variants iff items has a UNIQUE miss-band
witness (Self::has_unique_missing_variant holds) AND is the
sole variant whose per-target multiplicity sits at == 0, else
vec![]. Computed as the just-lifted set-level miss-band
uniqueness bit Self::has_unique_missing_variant guarding the
declaration-order miss-set witness-collection
Self::missing_variants: when the guard holds the collection
is already a length-1 Vec by the guard’s own definition
(count_missing == 1) and is lifted verbatim; when the guard
falsifies the projection collapses to the EMPTY Vec through a
zero-allocation ::std::vec::Vec::new() short-circuit. The
Vec<Self>-RETURN UNIQUE-TIE SHARPENING corner OPENING the
(set-level × Vec<Self> × equivalence-partition ×
multiplicity-band × unique-tie) column past the eight unsharpened
(declaration/lex × miss/repeat/unique/present) equivalence-
partition witness-collection peers (Self::missing_variants,
Self::sorted_missing_variants, Self::repeating_variants,
Self::sorted_repeating_variants, Self::unique_variants,
Self::sorted_unique_variants, Self::present_variants,
Self::sorted_present_variants) one UNIQUE-TIE-SHARPENING
axis over on the equivalence-partition surface AND peer to
Self::unique_extremal_variants (set-level × Vec<Self> ×
modal-aggregation × direction-composition × union × unique-tie)
one SURFACE axis over on the modal-aggregation matrix AND peer
to Self::unique_missing_variant (set-level × Option<Self>
× equivalence-partition × mult-band == 0 × unique-tie) one
RETURN-SHAPE axis over (Option-return witness-when-unique →
Vec-return singleton-or-empty-when-unique) AND peer to
Self::has_unique_missing_variant (set-level × bool ×
equivalence-partition × mult-band == 0 × unique-tie) one
RETURN-SHAPE axis over (bool uniqueness bit → Vec-return
singleton-or-empty carrier of the same bit). Not a fresh
substrate primitive on the index axis — the projection emerges
from the boolean-guarded selection of the declaration-order
miss-set witness-collection under the set-level miss-band
uniqueness bit, collapsing to the empty Vec through the guard-
arm when the bit falsifies. Read moreSource§fn unique_repeating_variants(items: &[Self]) -> Vec<Self>
fn unique_repeating_variants(items: &[Self]) -> Vec<Self>
Self::repeating_variants iff items has a UNIQUE strict-repeat
witness (Self::has_unique_repeating_variant holds) AND is the
sole variant whose per-target multiplicity sits at >= 2, else
vec![]. Computed as the just-lifted set-level strict-repeat
uniqueness bit Self::has_unique_repeating_variant guarding the
declaration-order strict-repeat witness-collection
Self::repeating_variants: when the guard holds the collection
is already a length-1 Vec by the guard’s own definition
(count_repeating_variants == 1) and is lifted verbatim; when the
guard falsifies the projection collapses to the EMPTY Vec through
a zero-allocation ::std::vec::Vec::new() short-circuit. The
Vec<Self>-RETURN UNIQUE-TIE SHARPENING corner CLOSING the strict-
repeat arm of the (set-level × Vec<Self> × equivalence-partition
× mult-band × unique-tie) row past the just-opened (mult == 0)
miss-band arm Self::unique_missing_variants one MULTIPLICITY-
BAND axis over on the equivalence-partition surface AND peer to
Self::unique_repeating_variant (set-level × Option<Self> ×
equivalence-partition × mult-band >= 2 × unique-tie) one RETURN-
SHAPE axis over (Option-return witness-when-unique → Vec-return
singleton-or-empty-when-unique) AND peer to
Self::has_unique_repeating_variant (set-level × bool ×
equivalence-partition × mult-band >= 2 × unique-tie) one RETURN-
SHAPE axis over (bool uniqueness bit → Vec-return singleton-or-
empty carrier of the same bit). Not a fresh substrate primitive
on the index axis — the projection emerges from the boolean-
guarded selection of the declaration-order strict-repeat witness-
collection under the set-level strict-repeat uniqueness bit,
collapsing to the empty Vec through the guard-arm when the bit
falsifies. Read moreSource§fn unique_unique_variants(items: &[Self]) -> Vec<Self>
fn unique_unique_variants(items: &[Self]) -> Vec<Self>
Self::unique_variants iff items has a UNIQUE (mult == 1)
witness (Self::has_unique_unique_variant holds) AND is the
sole variant whose per-target multiplicity sits EXACTLY at 1,
else vec![]. Computed as the just-lifted set-level unique-band
uniqueness bit Self::has_unique_unique_variant guarding the
declaration-order strict-uniqueness witness-collection
Self::unique_variants: when the guard holds the collection
is already a length-1 Vec by the guard’s own definition
(count_unique_variants == 1) and is lifted verbatim; when the
guard falsifies the projection collapses to the EMPTY Vec through
a zero-allocation ::std::vec::Vec::new() short-circuit. The
Vec<Self>-RETURN UNIQUE-TIE SHARPENING corner EXHAUSTIVELY
CLOSING the middle (mult == 1) arm of the (set-level ×
Vec<Self> × equivalence-partition × mult-band × unique-tie)
3-corner row on the EQUIVALENCE-PARTITION surface AT ITS FINAL
THIRD TILE past the (mult == 0) miss-band arm
Self::unique_missing_variants AND the (mult >= 2) strict-
repeat arm Self::unique_repeating_variants one MULTIPLICITY-
BAND axis over. Peer to Self::unique_unique_variant (set-
level × Option<Self> × equivalence-partition × mult == 1 ×
unique-tie) one RETURN-SHAPE axis over (Option-return witness-
when-unique → Vec-return singleton-or-empty-when-unique) AND
peer to Self::has_unique_unique_variant (set-level × bool
× equivalence-partition × mult == 1 × unique-tie) one RETURN-
SHAPE axis over (bool uniqueness bit → Vec-return singleton-or-
empty carrier of the same bit). Not a fresh substrate primitive
on the index axis — the projection emerges from the boolean-
guarded selection of the declaration-order strict-uniqueness
witness-collection under the set-level unique-band uniqueness
bit, collapsing to the empty Vec through the guard-arm when the
bit falsifies. Read moreSource§fn sorted_unique_missing_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_missing_variants(items: &[Self]) -> Vec<Self>
Self::sorted_missing_variants iff items has a UNIQUE absent
variant (Self::has_unique_missing_variant holds), else
vec![]. Computed as the just-lifted set-level miss-band
uniqueness bit Self::has_unique_missing_variant guarding the
LEX-ORDER miss-band witness-collection
Self::sorted_missing_variants: when the guard holds the
collection is already a length-1 Vec by the guard’s own
definition (count_missing_variants == 1) and is lifted
verbatim; when the guard falsifies the projection collapses to
the EMPTY Vec through a zero-allocation
::std::vec::Vec::new() short-circuit. The LEX-ORDER
Vec<Self>-RETURN MISS-BAND UNIQUE-TIE SHARPENING corner
OPENING the LEX-ORDER (Vec<Self> × equivalence-partition ×
mult-band × unique-tie) row past the just-closed declaration-
order trio (Self::unique_missing_variants,
Self::unique_repeating_variants,
Self::unique_unique_variants) one ORDERING axis over on the
EQUIVALENCE-PARTITION surface, peer to
Self::unique_missing_variants one ORDERING axis over
(declaration-order → lex-order miss-band witness-collection-
when-unique) AND peer to Self::sorted_missing_variants one
UNIQUE-TIE-SHARPENING axis over (unsharpened lex-order miss-band
witness-collection → uniqueness-gated lex-order miss-band
witness-collection) AND peer to
Self::sorted_unique_missing_variant one RETURN-SHAPE axis
over (Option-return lex-first-witness-when-unique → Vec-return
singleton-or-empty-when-unique) AND peer to
Self::sorted_unique_extremal_variants one SURFACE axis over
on the (Vec × sorted × unique-tie) face (EQUIVALENCE-PARTITION
miss-band → MODAL-AGGREGATION union band). Not a fresh substrate
primitive on the index axis — the projection emerges from the
boolean-guarded selection of the just-lifted lex-order miss-band
witness-collection under the set-level miss-band uniqueness bit,
collapsing to the empty Vec through the guard-arm when the bit
falsifies. Read moreSource§fn sorted_unique_repeating_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_repeating_variants(items: &[Self]) -> Vec<Self>
Self::sorted_repeating_variants iff items has a UNIQUE
strict-repeat variant (Self::has_unique_repeating_variant
holds), else vec![]. Computed as the just-lifted set-level
strict-repeat uniqueness bit Self::has_unique_repeating_variant
guarding the LEX-ORDER strict-repeat witness-collection
Self::sorted_repeating_variants: when the guard holds the
collection is already a length-1 Vec by the guard’s own
definition (count_repeating_variants == 1) and is lifted verbatim;
when the guard falsifies the projection collapses to the EMPTY Vec
through a zero-allocation ::std::vec::Vec::new() short-circuit.
The LEX-ORDER Vec<Self>-RETURN STRICT-REPEAT UNIQUE-TIE SHARPENING
corner CLOSING the strict-repeat arm of the LEX-ORDER (Vec<Self>
× equivalence-partition × mult-band × unique-tie) row past the
just-opened (mult == 0) miss-band arm
Self::sorted_unique_missing_variants one MULTIPLICITY-BAND axis
over on the EQUIVALENCE-PARTITION surface, peer to
Self::unique_repeating_variants one ORDERING axis over
(declaration-order → lex-order strict-repeat witness-collection-
when-unique) AND peer to Self::sorted_repeating_variants one
UNIQUE-TIE-SHARPENING axis over (unsharpened lex-order strict-
repeat witness-collection → uniqueness-gated lex-order strict-
repeat witness-collection) AND peer to
Self::sorted_unique_repeating_variant one RETURN-SHAPE axis
over (Option-return lex-first-witness-when-unique → Vec-return
singleton-or-empty-when-unique) AND peer to
Self::sorted_unique_extremal_variants one SURFACE axis over on
the (Vec × sorted × unique-tie) face (EQUIVALENCE-PARTITION strict-
repeat band → MODAL-AGGREGATION union band). Not a fresh substrate
primitive on the index axis — the projection emerges from the
boolean-guarded selection of the just-lifted lex-order strict-
repeat witness-collection under the set-level strict-repeat
uniqueness bit, collapsing to the empty Vec through the guard-arm
when the bit falsifies. Read moreSource§fn sorted_unique_unique_variants(items: &[Self]) -> Vec<Self>
fn sorted_unique_unique_variants(items: &[Self]) -> Vec<Self>
Self::sorted_unique_variants iff items has a UNIQUE unique-
band variant (Self::has_unique_unique_variant holds), else
vec![]. Computed as the just-lifted set-level unique-band
uniqueness bit Self::has_unique_unique_variant guarding the
LEX-ORDER strict-uniqueness witness-collection
Self::sorted_unique_variants: when the guard holds the
collection is already a length-1 Vec by the guard’s own
definition (count_unique_variants == 1) and is lifted verbatim;
when the guard falsifies the projection collapses to the EMPTY Vec
through a zero-allocation ::std::vec::Vec::new() short-circuit.
The LEX-ORDER Vec<Self>-RETURN UNIQUE-BAND UNIQUE-TIE SHARPENING
corner EXHAUSTIVELY CLOSING the middle (mult == 1) arm of the
LEX-ORDER (Vec<Self> × equivalence-partition × mult-band ×
unique-tie) row AT ITS FINAL THIRD TILE past the (mult == 0)
miss-band arm Self::sorted_unique_missing_variants AND the
(mult >= 2) strict-repeat arm
Self::sorted_unique_repeating_variants one MULTIPLICITY-BAND
axis over on the EQUIVALENCE-PARTITION surface — the row is now
the CANONICAL LEX-ORDER Vec<Self>-return unique-tie sharpening
on the equivalence-partition surface, closed at its FINAL third
tile AND EXHAUSTIVELY CLOSING the (Vec<Self> × equivalence-
partition × mult-band × ordering × unique-tie) 3×2 face at its
SIXTH tile. Peer to Self::unique_unique_variants one ORDERING
axis over (declaration-order → lex-order unique-band witness-
collection-when-unique) AND peer to
Self::sorted_unique_variants one UNIQUE-TIE-SHARPENING axis
over (unsharpened lex-order strict-uniqueness witness-collection →
uniqueness-gated lex-order unique-band witness-collection) AND
peer to Self::sorted_unique_unique_variant one RETURN-SHAPE
axis over (Option-return lex-first-witness-when-unique → Vec-
return singleton-or-empty-when-unique). Not a fresh substrate
primitive on the index axis — the projection emerges from the
boolean-guarded selection of the LEX-ORDER strict-uniqueness
witness-collection under the set-level unique-band uniqueness bit,
collapsing to the empty Vec through the guard-arm when the bit
falsifies. Read moreSource§fn is_uniformly_repeating(items: &[Self]) -> bool
fn is_uniformly_repeating(items: &[Self]) -> bool
true iff EVERY variant of Self::ALL appears AT LEAST TWICE
in items, computed as the just-lifted set-level scalar
Self::min_variant_count projection’s lower-bound test against
2. The BOOL-RETURN closer on the (set-level × bool × universal-
lift × multiplicity-band) 4th-axis hypercube at the universal-
lift >= 2 corner peer to the pre-existing (set-level × bool ×
universal-lift × multiplicity-band >= 1) Self::is_covering
corner one MULTIPLICITY-BAND axis over AND peer to the pre-
existing (set-level × bool × universal-lift × multiplicity-band
<= 1) Self::is_pairwise_distinct corner one MULTIPLICITY-
BAND axis over on the SAME universal-lift arm of the quantifier
axis, AND the direct SET-LEVEL UNIVERSAL PEER of the (set-level
× bool × existential-lift × multiplicity-band >= 2)
Self::is_repeating_any corner one QUANTIFIER axis over on
the SAME multiplicity band. Not a fresh substrate primitive on
the index axis — the predicate emerges from ONE lower-bound
scalar comparison against the substrate’s just-lifted set-level
least-common-multiplicity aggregate. Read moreSource§fn present_labels(items: &[Self]) -> Vec<&'static str>
fn present_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of Self::present_variants
under Self::label. Every label s in the returned vector is
the canonical Self::label rendering of some variant present
in items; the declaration order of Self::present_variants
is preserved verbatim. Read moreSource§fn present_labels_joined(items: &[Self], sep: &str) -> String
fn present_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::present_labels joined by
sep. Composes the substrate’s declaration-axis hit-label
Vec-return primitive with the standard-library
slice::join
combinator so a passing implementor of Self::present_labels
automatically satisfies this projection at every downstream
site. Read moreSource§fn missing_labels(items: &[Self]) -> Vec<&'static str>
fn missing_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of Self::missing_variants
under Self::label. Every label s in the returned vector is
the canonical Self::label rendering of some variant ABSENT
from items; the declaration order of Self::missing_variants
is preserved verbatim. The DE MORGAN dual of
Self::present_labels one partition-arm axis over on the label-
return column of the equivalence-partition surface. Read moreSource§fn missing_labels_joined(items: &[Self], sep: &str) -> String
fn missing_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::missing_labels joined by
sep. Composes the substrate’s declaration-axis miss-label
Vec-return primitive with the standard-library
slice::join
combinator so a passing implementor of Self::missing_labels
automatically satisfies this projection at every downstream
site. The DE MORGAN dual of Self::present_labels_joined
one partition-arm axis over on the String-return column of
the equivalence-partition surface, and the DECLARATION-ORDER
arm of the (present, absent) × (declaration, lex) 2×2 = 4-corner
join-string face this projection closes past its
Self::present_labels_joined sibling. Read moreSource§fn repeating_labels(items: &[Self]) -> Vec<&'static str>
fn repeating_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of Self::repeating_variants
under Self::label. Every label s in the returned vector is
the canonical Self::label rendering of some variant appearing
STRICTLY MORE THAN ONCE (multiplicity >= 2) in items; the
declaration order of Self::repeating_variants is preserved
verbatim. The (multiplicity >= 2) STRICT-REPEAT band peer of
Self::present_labels (multiplicity >= 1) and
Self::missing_labels (multiplicity == 0) one MULTIPLICITY-
BAND axis over on the equivalence-partition surface — OPENS the
(repeating, Vec<&'static str> label, declaration-order) corner
past the pre-existing (present, Vec<&'static str> label,
declaration-order) and (absent, Vec<&'static str> label,
declaration-order) doublet on the label-return column. Read moreSource§fn repeating_labels_joined(items: &[Self], sep: &str) -> String
fn repeating_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::repeating_labels joined by
sep. Composes the substrate’s declaration-axis strict-repeat
label-Vec primitive with the standard-library
slice::join
combinator so a passing implementor of Self::repeating_labels
automatically satisfies this projection at every downstream site.
The (multiplicity >= 2) STRICT-REPEAT band peer of
Self::present_labels_joined (multiplicity >= 1) and
Self::missing_labels_joined (multiplicity == 0) one
MULTIPLICITY-BAND axis over on the declaration-order String-
return column of the equivalence-partition surface —
EXHAUSTIVELY CLOSES the (partition-band × String ×
declaration-order) 3-tile row at its FINAL third tile past
the pre-existing (present, String, declaration) and
(absent, String, declaration) doublet. Read moreSource§fn sorted_present_labels(items: &[Self]) -> Vec<&'static str>
fn sorted_present_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of
Self::sorted_present_variants under Self::label. Every
label s in the returned vector is the canonical
Self::label rendering of some variant present in items;
the lex order of Self::sorted_present_variants is preserved
verbatim. The LEX-ORDER peer of Self::present_labels on the
(declaration, lex) ordering axis of the label-return column of
the equivalence-partition surface — opens the lex arm past the
declaration arm the sibling Self::present_labels closed. Read moreSource§fn sorted_present_labels_joined(items: &[Self], sep: &str) -> String
fn sorted_present_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::sorted_present_labels joined by
sep. Composes the substrate’s lex-axis hit-label Vec-return
primitive with the standard-library
slice::join
combinator so a passing implementor of
Self::sorted_present_labels automatically satisfies this
projection at every downstream site. The LEX-ORDER peer of
Self::present_labels_joined one ordering axis over on the
(declaration, lex) axis of the join-string column of the
equivalence-partition surface — opens the lex arm past the
declaration arm the sibling Self::present_labels_joined
closed. Read moreSource§fn sorted_missing_labels(items: &[Self]) -> Vec<&'static str>
fn sorted_missing_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of
Self::sorted_missing_variants under Self::label. Every
label s in the returned vector is the canonical
Self::label rendering of some variant ABSENT from items;
the lex order of Self::sorted_missing_variants is preserved
verbatim. The DE MORGAN dual of Self::sorted_present_labels
one partition-arm axis over on the lex-order arm of the label-
return column of the equivalence-partition surface, and the
LEX-ORDER peer of Self::missing_labels on the (declaration,
lex) ordering axis. Read moreSource§fn sorted_missing_labels_joined(items: &[Self], sep: &str) -> String
fn sorted_missing_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::sorted_missing_labels joined by
sep. Composes the substrate’s lex-axis miss-label Vec-return
primitive with the standard-library
slice::join
combinator so a passing implementor of
Self::sorted_missing_labels automatically satisfies this
projection at every downstream site. The FOURTH corner CLOSING
the (partition-arm × ordering) 2×2 = 4-corner join-string face
on the label-join column of the equivalence-partition surface
past the pre-existing corners at Self::present_labels_joined
(present × decl), Self::missing_labels_joined (absent × decl),
and Self::sorted_present_labels_joined (present × lex). The
LEX-ORDER peer of Self::missing_labels_joined one ordering
axis over, and the DE MORGAN dual of
Self::sorted_present_labels_joined one partition-arm axis
over. Read moreSource§fn sorted_repeating_labels(items: &[Self]) -> Vec<&'static str>
fn sorted_repeating_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of
Self::sorted_repeating_variants under Self::label. Every
label s in the returned vector is the canonical
Self::label rendering of some variant whose per-target
multiplicity in items is >= 2; the lex order of
Self::sorted_repeating_variants is preserved verbatim. The
LEX-ORDER peer of Self::repeating_labels one ORDERING axis
over on the equivalence-partition surface — opens the lex arm
of the (strict-repeat × Vec<&'static str>) column past the
declaration arm the sibling Self::repeating_labels closed,
mirroring Self::sorted_present_labels opening its lex arm
past Self::present_labels and Self::sorted_missing_labels
opening its lex arm past Self::missing_labels. Read moreSource§fn sorted_repeating_labels_joined(items: &[Self], sep: &str) -> String
fn sorted_repeating_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::sorted_repeating_labels joined by
sep. Composes the substrate’s lex-axis strict-repeat-label
Vec-return primitive with the standard-library
slice::join
combinator so a passing implementor of
Self::sorted_repeating_labels automatically satisfies this
projection at every downstream site. The SIXTH corner
EXHAUSTIVELY CLOSING the (partition-band × ordering) 3×2 =
6-corner join-string face on the label-join column of the
equivalence-partition surface past the pre-existing quintet at
Self::present_labels_joined (present × decl),
Self::missing_labels_joined (absent × decl),
Self::repeating_labels_joined (repeating × decl),
Self::sorted_present_labels_joined (present × lex), and
Self::sorted_missing_labels_joined (absent × lex). The
LEX-ORDER peer of Self::repeating_labels_joined one ORDERING
axis over, and the mult-band >= 2 peer of
Self::sorted_missing_labels_joined +
Self::sorted_present_labels_joined one PARTITION-BAND axis
over on the lex arm. Read moreSource§fn present_indices(items: &[Self]) -> Vec<usize>
fn present_indices(items: &[Self]) -> Vec<usize>
Vec<usize> Self::ALL-index rendering of
Self::present_variants under Self::index_of. Every
usize i in the returned vector is the Self::ALL-position
of some variant present in items; the declaration order of
Self::present_variants is preserved verbatim, so the
returned indices form a STRICTLY ASCENDING subsequence of
0..Self::CARDINALITY. The VEC-INDEX-RETURN present-arm opener
on the (VecSelf::present_variants, Self::missing_variants,
Self::sorted_present_variants, Self::sorted_missing_variants,
Self::present_labels, Self::missing_labels,
Self::sorted_present_labels, Self::sorted_missing_labels
closed. Read moreSource§fn missing_indices(items: &[Self]) -> Vec<usize>
fn missing_indices(items: &[Self]) -> Vec<usize>
Vec<usize> Self::ALL-index rendering of
Self::missing_variants under Self::index_of. Every
usize i in the returned vector is the Self::ALL-position
of some variant ABSENT from items; the declaration order of
Self::missing_variants is preserved verbatim, so the
returned indices form a STRICTLY ASCENDING subsequence of
0..Self::CARDINALITY. The DE MORGAN dual of
Self::present_indices one partition-arm axis over on the
index-return column of the equivalence-partition surface. Read moreSource§fn sorted_present_indices(items: &[Self]) -> Vec<usize>
fn sorted_present_indices(items: &[Self]) -> Vec<usize>
Vec<usize> Self::ALL-index rendering of
Self::sorted_present_variants under Self::index_of. Every
usize i in the returned vector is the Self::ALL-position
of some variant present in items; the lex order of
Self::sorted_present_variants is preserved verbatim, so the
returned indices form a subsequence of
Self::sorted_variants-under-Self::index_of (whose
declaration-axis peer Self::present_indices is a subsequence
of 0..Self::CARDINALITY in strictly ascending order). The
LEX-ORDER peer of Self::present_indices on the (declaration,
lex) ordering axis of the index-return column of the
equivalence-partition surface. Read moreSource§fn sorted_missing_indices(items: &[Self]) -> Vec<usize>
fn sorted_missing_indices(items: &[Self]) -> Vec<usize>
Vec<usize> Self::ALL-index rendering of
Self::sorted_missing_variants under Self::index_of. Every
usize i in the returned vector is the Self::ALL-position
of some variant ABSENT from items; the lex order of
Self::sorted_missing_variants is preserved verbatim. The DE
MORGAN dual of Self::sorted_present_indices one partition-arm
axis over on the lex-order arm of the index-return column of the
equivalence-partition surface, and the LEX-ORDER peer of
Self::missing_indices on the (declaration, lex) ordering
axis — EXHAUSTIVELY CLOSES the (index-return × ordering) 2×2 =
4-corner face on the index-return column past the three prior
corners. Read moreSource§fn repeating_indices(items: &[Self]) -> Vec<usize>
fn repeating_indices(items: &[Self]) -> Vec<usize>
Vec<usize> Self::ALL-index rendering of
Self::repeating_variants under Self::index_of. Every
usize i in the returned vector is the Self::ALL-position
of some variant appearing STRICTLY MORE THAN ONCE (multiplicity
>= 2) in items; the declaration order of
Self::repeating_variants is preserved verbatim, so the
returned indices form a STRICTLY ASCENDING subsequence of
0..Self::CARDINALITY. The (multiplicity >= 2) STRICT-REPEAT
band peer of Self::present_indices (multiplicity >= 1) and
Self::missing_indices (multiplicity == 0) one MULTIPLICITY-
BAND axis over on the index-return column of the equivalence-
partition surface — OPENS the (repeating, Vec<usize> index,
declaration-order) corner past the exhaustively-closed
(index-return × ordering) 2×2 = 4-corner face on the (present,
absent) doublet that Self::present_indices,
Self::missing_indices, Self::sorted_present_indices,
Self::sorted_missing_indices closed. Peer to
Self::repeating_labels one RETURN-SHAPE column over on the
same multiplicity band — same partition-arm, same declaration
order, different Vec-return projection (Vec<usize> vs
Vec<&'static str>). Read moreSource§fn sorted_repeating_indices(items: &[Self]) -> Vec<usize>
fn sorted_repeating_indices(items: &[Self]) -> Vec<usize>
Vec<usize> Self::ALL-index rendering of
Self::sorted_repeating_variants under Self::index_of.
Every usize i in the returned vector is the Self::ALL-
position of some variant appearing STRICTLY MORE THAN ONCE
(multiplicity >= 2) in items; the lex order of
Self::sorted_repeating_variants is preserved verbatim, so the
returned indices form a canonical LEX-order subsequence of
Self::sorted_variants under Self::index_of — which is
NOT in general a monotone subsequence of 0..Self::CARDINALITY
on implementors whose declaration order diverges from
Self::sorted_labels. The LEX-ORDER peer of
Self::repeating_indices one ORDERING axis over on the
equivalence-partition surface — EXHAUSTIVELY CLOSES the
(partition-band × ordering) 3×2 = 6-corner face on the
index-return column at its FINAL sixth tile past the pre-
existing quintet of Self::present_indices,
Self::missing_indices, Self::repeating_indices,
Self::sorted_present_indices, and Self::sorted_missing_indices,
mirroring the exhaustively-closed (partition-band × ordering) 3×2
face on the sibling label-Vec-return column that
Self::sorted_repeating_labels closed one return-shape axis
over. Read moreSource§fn present_indices_joined(items: &[Self], sep: &str) -> String
fn present_indices_joined(items: &[Self], sep: &str) -> String
String rendering of Self::present_indices under
usize::to_string joined by sep. Composes the substrate’s
declaration-axis hit-index Vec-return primitive with the
per-slot usize-to-String projection and the standard-library
slice::join
combinator so a passing implementor of Self::present_indices
automatically satisfies this projection at every downstream
site. OPENS the (indices, joined) column of the (partition-band
× ordering × return-shape) 3×2×2 = 12-tile equivalence-partition
index-aggregation surface past the exhaustively-closed 6-corner
(partition-band × ordering) Vec-return face at Self::present_indices
/ Self::missing_indices / Self::repeating_indices /
Self::sorted_present_indices / Self::sorted_missing_indices
/ Self::sorted_repeating_indices one RETURN-SHAPE axis over. Read moreSource§fn missing_indices_joined(items: &[Self], sep: &str) -> String
fn missing_indices_joined(items: &[Self], sep: &str) -> String
Self::missing_indices Vec-return miss-
witness index list stringified per slot under usize::to_string
and threaded into a single String under the caller’s separator. Read moreSource§fn repeating_indices_joined(items: &[Self], sep: &str) -> String
fn repeating_indices_joined(items: &[Self], sep: &str) -> String
Self::repeating_indices Vec-return
strict-repeat-witness index list stringified per slot under
usize::to_string and threaded into a single String under the
caller’s separator. Read moreSource§fn sorted_present_indices_joined(items: &[Self], sep: &str) -> String
fn sorted_present_indices_joined(items: &[Self], sep: &str) -> String
String rendering of Self::sorted_present_indices under
usize::to_string joined by sep. Composes the substrate’s
lex-axis hit-index Vec-return primitive with the per-slot
usize-to-String projection and the standard-library
slice::join
combinator so a passing implementor of
Self::sorted_present_indices automatically satisfies this
projection at every downstream site. OPENS the LEX-ORDER row of
the (partition-band × ordering × join-string) 3×2 = 6-corner
face on the index-join column of the equivalence-partition
index-aggregation surface past the just-closed declaration-order
row at Self::present_indices_joined, Self::missing_indices_joined,
and Self::repeating_indices_joined one ORDERING axis over. Read moreSource§fn sorted_missing_indices_joined(items: &[Self], sep: &str) -> String
fn sorted_missing_indices_joined(items: &[Self], sep: &str) -> String
String rendering of Self::sorted_missing_indices under
usize::to_string joined by sep. Composes the substrate’s
lex-axis miss-index Vec-return primitive with the per-slot
usize-to-String projection and the standard-library
slice::join
combinator so a passing implementor of
Self::sorted_missing_indices automatically satisfies this
projection at every downstream site. CLOSES the miss-arm one
PARTITION-BAND axis over on the LEX-ORDER row of the (partition-
band × ordering × join-string) 3×2 = 6-corner face on the index-
join column of the equivalence-partition index-aggregation
surface past the just-opened Self::sorted_present_indices_joined
present-arm one PARTITION-BAND axis over. Read moreSource§fn unique_missing_labels(items: &[Self]) -> Vec<&'static str>
fn unique_missing_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of
Self::unique_missing_variants under Self::label. Every
label s in the returned vector is the canonical
Self::label rendering of some variant ABSENT from items AND
the SOLE absent variant (the miss-band uniqueness guard
Self::has_unique_missing_variant holds). When the guard
falsifies the projection collapses to the EMPTY Vec through a
zero-allocation short-circuit inherited from
Self::unique_missing_variants. Read moreSource§fn unique_repeating_labels(items: &[Self]) -> Vec<&'static str>
fn unique_repeating_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of
Self::unique_repeating_variants under Self::label. Every
label s in the returned vector is the canonical
Self::label rendering of some variant that appears TWO-OR-MORE
times in items AND is the SOLE strict-repeat variant (the
strict-repeat uniqueness guard
Self::has_unique_repeating_variant holds). When the guard
falsifies the projection collapses to the EMPTY Vec through a
zero-allocation short-circuit inherited from
Self::unique_repeating_variants. Read moreSource§fn unique_unique_labels(items: &[Self]) -> Vec<&'static str>
fn unique_unique_labels(items: &[Self]) -> Vec<&'static str>
Vec<&'static str> label rendering of
Self::unique_unique_variants under Self::label. Every
label s in the returned vector is the canonical
Self::label rendering of some variant that appears EXACTLY
ONCE in items AND is the SOLE unique-band variant (the
unique-band uniqueness guard Self::has_unique_unique_variant
holds). When the guard falsifies the projection collapses to
the EMPTY Vec through a zero-allocation short-circuit inherited
from Self::unique_unique_variants. Read moreSource§fn unique_missing_labels_joined(items: &[Self], sep: &str) -> String
fn unique_missing_labels_joined(items: &[Self], sep: &str) -> String
String
rendering of Self::unique_missing_labels joined by sep.
Composes the substrate’s just-lifted uniqueness-gated miss-band
label-Vec primitive with the standard-library
slice::join
combinator so a passing implementor of
Self::unique_missing_labels automatically satisfies this
projection at every downstream site. When the miss-band uniqueness
guard Self::has_unique_missing_variant holds, the projection
returns the sole absent variant’s label as a bare String (no
separator surfaces because the joined slice is a singleton); when
the guard falsifies, the projection collapses to the EMPTY
String through a zero-allocation short-circuit inherited from
Self::unique_missing_labels. Read moreSource§fn unique_repeating_labels_joined(items: &[Self], sep: &str) -> String
fn unique_repeating_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::unique_repeating_labels joined by
sep. Composes the substrate’s just-lifted uniqueness-gated
strict-repeat label-Vec primitive with the standard-library
slice::join
combinator so a passing implementor of
Self::unique_repeating_labels automatically satisfies this
projection at every downstream site. When the strict-repeat
uniqueness guard Self::has_unique_repeating_variant holds,
the projection returns the sole repeated variant’s label as a
bare String (no separator surfaces because the joined slice is
a singleton); when the guard falsifies, the projection collapses
to the EMPTY String through a zero-allocation short-circuit
inherited from Self::unique_repeating_labels. Read moreSource§fn unique_unique_labels_joined(items: &[Self], sep: &str) -> String
fn unique_unique_labels_joined(items: &[Self], sep: &str) -> String
String rendering of Self::unique_unique_labels joined by
sep. Composes the substrate’s just-lifted uniqueness-gated
unique-band label-Vec primitive with the standard-library
slice::join
combinator so a passing implementor of
Self::unique_unique_labels automatically satisfies this
projection at every downstream site. When the unique-band
uniqueness guard Self::has_unique_unique_variant holds, the
projection returns the sole once-occurring variant’s label as a
bare String (no separator surfaces because the joined slice
is a singleton); when the guard falsifies, the projection
collapses to the EMPTY String through a zero-allocation
short-circuit inherited from Self::unique_unique_labels. Read moreSource§fn is_between(self, lo: Self, hi: Self) -> bool
fn is_between(self, lo: Self, hi: Self) -> bool
true iff self sits in the closed range
[lo, hi] of Self::ALL’s declaration order, false when
self sits strictly before lo OR strictly after hi. The
TERNARY-arity opener on the closed-set surface, past the
exhaustively-closed 8-corner (ordering × direction × strictness)
2×2×2 pairwise-comparison hypercube (78)+(79)+(80)+(81) — opens
the arity axis one step further from binary pairwise-comparison
to ternary closed-range containment. Read moreSource§fn is_sorted_between(self, lo: Self, hi: Self) -> bool
fn is_sorted_between(self, lo: Self, hi: Self) -> bool
true iff self sits in the closed range
[lo, hi] of the lex-order Self::sorted_labels, false
when self sits strictly before lo OR strictly after hi
in lex order. The lex-ordering peer of Self::is_between on
the (declaration, lex) ordering axis of the ternary closed-
range containment surface. Read moreSource§fn is_strictly_between(self, lo: Self, hi: Self) -> bool
fn is_strictly_between(self, lo: Self, hi: Self) -> bool
true iff self sits STRICTLY inside the open
range (lo, hi) of the declaration-order Self::ALL,
false when self coincides with EITHER endpoint OR sits
outside. The strict-precedence peer of Self::is_between on
the (endpoint-inclusivity) axis of the ternary closed-range
containment surface — opens the (exclusive-both) corner of the
4-corner (ordering × endpoint-inclusivity-flavor) matrix past
the (inclusive-both) corner (82)+(83) Self::is_between /
Self::is_sorted_between closed. Read moreSource§fn is_sorted_strictly_between(self, lo: Self, hi: Self) -> bool
fn is_sorted_strictly_between(self, lo: Self, hi: Self) -> bool
true iff self sits STRICTLY inside the open range
(lo, hi) of the lex-order Self::sorted_labels, false
when self coincides with EITHER endpoint OR sits outside in
lex order. The lex-ordering peer of Self::is_strictly_between
on the (declaration, lex) ordering axis of the ternary strict-
open-range containment surface. Read moreSource§fn is_right_half_open_between(self, lo: Self, hi: Self) -> bool
fn is_right_half_open_between(self, lo: Self, hi: Self) -> bool
true iff self sits in the half-open range
[lo, hi) of the declaration-order Self::ALL, false when
self coincides with the upper endpoint hi, sits strictly
before lo, OR sits strictly after hi. The “canonical
half-open” arm on the (endpoint-inclusivity-flavor) axis of the
ternary closed-range containment surface — mirroring
std::ops::Range::contains, Python range(), and the standard
mathematical [lo, hi) interval notation where the RIGHT
endpoint is the OPEN one. Read moreSource§fn is_sorted_right_half_open_between(self, lo: Self, hi: Self) -> bool
fn is_sorted_right_half_open_between(self, lo: Self, hi: Self) -> bool
true iff self sits in the half-open range
[lo, hi) of the lex-order Self::sorted_labels, false
when self coincides with the upper endpoint hi, sits
strictly before lo OR strictly after hi in lex order. The
lex-ordering peer of Self::is_right_half_open_between on
the (declaration, lex) ordering axis of the ternary right-
half-open-range containment surface. Read moreSource§fn is_left_half_open_between(self, lo: Self, hi: Self) -> bool
fn is_left_half_open_between(self, lo: Self, hi: Self) -> bool
true iff self sits in the half-open range
(lo, hi] of the declaration-order Self::ALL, false when
self coincides with the lower endpoint lo, sits strictly
before lo, OR sits strictly after hi. The MIRROR
asymmetric-mix on the (endpoint-inclusivity-flavor) axis of the
ternary closed-range containment surface — mirroring the
mathematical (lo, hi] interval notation where the LEFT
endpoint is the OPEN one, and Kotlin’s absent-but-natural
v in lo<..hi left-exclusive-range shape (Kotlin exposes
..< for right-half-open but not the mirror; the substrate
closes both flavors symmetrically). Read moreSource§fn is_sorted_left_half_open_between(self, lo: Self, hi: Self) -> bool
fn is_sorted_left_half_open_between(self, lo: Self, hi: Self) -> bool
true iff self sits in the half-open range
(lo, hi] of the lex-order Self::sorted_labels, false
when self coincides with the lower endpoint lo, sits
strictly before lo OR strictly after hi in lex order. The
lex-ordering peer of Self::is_left_half_open_between on
the (declaration, lex) ordering axis of the ternary left-
half-open-range containment surface. Read moreSource§fn clamp(self, lo: Self, hi: Self) -> Self
fn clamp(self, lo: Self, hi: Self) -> Self
Self::is_between on the
(return-shape) axis of the ternary closed-range surface.
Given a well-formed range [lo, hi] with
lo.precedes_or_equal(hi), projects self INTO the range by
(a) returning lo when self strictly precedes lo, (b)
returning hi when hi strictly precedes self, and (c)
returning self unchanged otherwise. The typed
value-projection dual of the eight-corner
(ordering × endpoint-inclusivity-flavor) bool-return ternary
containment hypercube (is_between (82)+(83),
is_strictly_between (84)+(85), is_right_half_open_between
(86)+(87), is_left_half_open_between (88)+(89)) — where the
eight bool-return corners answer “does self sit in the
range?”, this projection answers “what variant IN the range
does self project to?”. Read moreSource§fn sorted_clamp(self, lo: Self, hi: Self) -> Self
fn sorted_clamp(self, lo: Self, hi: Self) -> Self
Self::is_sorted_between on the (return-shape)
axis of the ternary closed-range surface. Given a well-formed
lex-range [lo, hi] with lo.sorted_precedes_or_equal(hi),
projects self INTO the lex-range by returning lo when
self strictly lex-precedes lo, returning hi when hi
strictly lex-precedes self, and returning self unchanged
otherwise. The lex-ordering peer of Self::clamp on the
(declaration, lex) ordering axis of the ternary Self-return
closed-range surface. Read moreSource§fn clamp_label(self, lo: Self, hi: Self) -> &'static str
fn clamp_label(self, lo: Self, hi: Self) -> &'static str
&'static str LABEL of the declaration-order
ternary-CLAMP projection of self into the closed range
[lo, hi] — the label of Self::clamp projected through
Self::label. Returns &'static str, never
Option<&'static str>: the ternary clamp projection is
TOTAL on well-formed ranges (every well-formed triple lands
on a variant in the closed range, and every variant carries
a canonical label). Read moreSource§fn sorted_clamp_label(self, lo: Self, hi: Self) -> &'static str
fn sorted_clamp_label(self, lo: Self, hi: Self) -> &'static str
&'static str LABEL of the lex-order ternary-
CLAMP projection of self into the closed lex-range
[lo, hi] — the label of Self::sorted_clamp projected
through Self::label. Returns &'static str, never
Option<&'static str>. Read moreSource§fn clamp_index(self, lo: Self, hi: Self) -> usize
fn clamp_index(self, lo: Self, hi: Self) -> usize
usize DECLARATION-ORDER INDEX of the declaration-order
ternary-CLAMP projection of self into the closed range
[lo, hi] — the declaration-order position of
Self::clamp projected through Self::index_of.
Returns usize, never Option<usize>: the ternary clamp
projection is TOTAL on well-formed ranges, and every
variant carries a declaration-order slot. Read moreSource§fn sorted_clamp_index(self, lo: Self, hi: Self) -> usize
fn sorted_clamp_index(self, lo: Self, hi: Self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the lex-order
ternary-CLAMP projection of self into the closed lex-range
[lo, hi] — the lex position of Self::sorted_clamp
projected through Self::sorted_index_of. Returns usize,
never Option<usize>. Read moreSource§fn saturating_next(self) -> Self
fn saturating_next(self) -> Self
self in
Self::ALL, SATURATING at self at the tail — the third arm
of the (boundary-behavior) axis on the closed-set forward-
declaration-neighbor surface past the pre-existing
(Option-typed-bounded, Self-typed-wrapping) partition:
Self::next returns None at the tail, Self::cycle_next
FOLDS the tail-endpoint boundary onto Self::first, and THIS
method PINS self at the tail-endpoint boundary — the
“stay-at-boundary” arm of the three-way boundary-behavior
partition. Returns Self, never Option<Self>: the
saturating arm folds the tail-endpoint boundary onto self
itself rather than wrapping to the head (Self::cycle_next)
or leaving the None the bounded arm (Self::next) returns. Read moreSource§fn saturating_prev(self) -> Self
fn saturating_prev(self) -> Self
self in
Self::ALL, SATURATING at self at the head —
self.prev().unwrap_or(self). Returns Self, never
Option<Self>: the saturating arm folds the head-endpoint
boundary onto self itself rather than wrapping to the tail
(Self::cycle_prev) or leaving the None the bounded
arm (Self::prev) returns. Read moreSource§fn sorted_saturating_next(self) -> Self
fn sorted_saturating_next(self) -> Self
self in
Self::sorted_variants, SATURATING at self at the lex
tail — self.sorted_next().unwrap_or(self). Returns
Self, never Option<Self>: the saturating arm folds
the lex-tail-endpoint boundary onto self itself rather
than wrapping to the lex head (Self::cycle_sorted_next)
or leaving the None the bounded lex arm
(Self::sorted_next) returns. Read moreSource§fn sorted_saturating_prev(self) -> Self
fn sorted_saturating_prev(self) -> Self
self in
Self::sorted_variants, SATURATING at self at the lex
head — self.sorted_prev().unwrap_or(self). Returns
Self, never Option<Self>: the saturating arm folds
the lex-head-endpoint boundary onto self itself rather
than wrapping to the lex tail (Self::cycle_sorted_prev)
or leaving the None the bounded lex arm
(Self::sorted_prev) returns. Read moreSource§fn saturating_next_label(self) -> &'static str
fn saturating_next_label(self) -> &'static str
&'static str LABEL of the declaration-order
neighbor immediately AFTER self in Self::ALL, SATURATING
at Self::label at the tail — the label of
Self::saturating_next projected through Self::label.
Returns &'static str, never Option<&'static str>: the
saturating arm folds the tail-endpoint boundary onto self’s
OWN label rather than wrapping to Self::first_label (the
wrapping arm’s Self::cycle_next_label fold) or leaving the
None the bounded arm (Self::next_label) returns. Read moreSource§fn saturating_prev_label(self) -> &'static str
fn saturating_prev_label(self) -> &'static str
&'static str LABEL of the declaration-order
neighbor immediately BEFORE self in Self::ALL, SATURATING
at Self::label at the head — the label of
Self::saturating_prev projected through Self::label.
Returns &'static str, never Option<&'static str>. Read moreSource§fn sorted_saturating_next_label(self) -> &'static str
fn sorted_saturating_next_label(self) -> &'static str
&'static str LABEL of the lexicographic-order
neighbor immediately AFTER self in Self::sorted_variants,
SATURATING at Self::label at the lex tail — the label of
Self::sorted_saturating_next projected through
Self::label. Returns &'static str, never
Option<&'static str>. Read moreSource§fn sorted_saturating_prev_label(self) -> &'static str
fn sorted_saturating_prev_label(self) -> &'static str
&'static str LABEL of the lexicographic-order
neighbor immediately BEFORE self in Self::sorted_variants,
SATURATING at Self::label at the lex head — the label of
Self::sorted_saturating_prev projected through
Self::label. Returns &'static str, never
Option<&'static str>. Read moreSource§fn saturating_next_index(self) -> usize
fn saturating_next_index(self) -> usize
usize DECLARATION-ORDER INDEX of the neighbor immediately
AFTER self in Self::ALL, SATURATING at
Self::index_of(self) at the tail — the declaration-order
position of Self::saturating_next projected through
Self::index_of. Returns usize, never Option<usize>:
the saturating arm folds the tail-endpoint boundary onto
self’s OWN slot rather than wrapping to 0 (the wrapping
arm’s Self::cycle_next_index fold) or leaving the None
the bounded arm (Self::next_index) returns. Read moreSource§fn saturating_prev_index(self) -> usize
fn saturating_prev_index(self) -> usize
usize DECLARATION-ORDER INDEX of the neighbor immediately
BEFORE self in Self::ALL, SATURATING at
Self::index_of(self) at the head — the declaration-order
position of Self::saturating_prev projected through
Self::index_of. Returns usize, never Option<usize>. Read moreSource§fn sorted_saturating_next_index(self) -> usize
fn sorted_saturating_next_index(self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the neighbor
immediately AFTER self in Self::sorted_variants,
SATURATING at Self::sorted_index_of(self) at the lex
tail — the lex position of Self::sorted_saturating_next
projected through Self::sorted_index_of. Returns usize,
never Option<usize>. Read moreSource§fn sorted_saturating_prev_index(self) -> usize
fn sorted_saturating_prev_index(self) -> usize
usize LEXICOGRAPHIC-ORDER INDEX of the neighbor
immediately BEFORE self in Self::sorted_variants,
SATURATING at Self::sorted_index_of(self) at the lex
head — the lex position of Self::sorted_saturating_prev
projected through Self::sorted_index_of. Returns usize,
never Option<usize>. Read more