pub enum ValidationWarning {
DegenerateGeometric {
strategy: StrategyName,
},
LhsDegenerate,
TriviallyTrueFilter,
TriviallyFalseFilter,
EmptySource {
var: String,
source: Option<String>,
},
SingletonCombinator {
combinator: &'static str,
},
UnresolvedNames {
reads: Vec<NameRead>,
},
}Expand description
Non-blocking warning for degenerate-but-defined compositions (comprehension_forms.md §5.8).
Variants§
DegenerateGeometric
Lattice-geometric strategy (Extrema / Shells /
Diagonal / Antidiagonal) over a 1-axis input.
Collapses to {first, last} or a trivial walk; usually
not what the author meant.
Fields
strategy: StrategyNameThe strategy applied.
LhsDegenerate
Lhs over a 1-axis input. Equivalent to Shuffle;
two names for one behavior.
TriviallyTrueFilter
filter(c, "true"). Empty-effect filter — usually a
bug-shaped predicate. The optimizer’s R0a elides it.
TriviallyFalseFilter
filter(c, "false"). Empty dispense sequence. If
intentional, use an empty literal source; otherwise the
predicate is bug-shaped.
EmptySource
A clause whose source is provably empty: its cardinality
is Bounded(0) (x in [], x in 5..5, a context-free
generator the compile evaluated to nothing). The clause is
well-formed and an empty stream is a legal value, so this
is degenerate rather than wrong — but it empties every
cartesian it takes part in, so a whole traversal dispenses
nothing and usually that is a typo in the source.
A source whose count is not known at construction (an
interpolated call, a parameter without a length) is
Unbounded, never Bounded(0), so it cannot reach here:
emptiness it discovers at evaluation is reported by the
per-clause yields instead (super::runtime::ClauseYield).
Fields
SingletonCombinator
Singleton variant of a combinator: zip([c], _),
cartesian(c), union(c). Identity per
comprehension_forms.md §4.2 I1-I3; the optimizer’s R0a
elides it.
UnresolvedNames
V3 outside strictness (§5 V3): names the comprehension reads
that neither it binds nor the surface supplies. The comprehension
compiles, and each such name reads None. A Strict compile
refuses it as ValidationError::V3UnresolvedNames.
Trait Implementations§
Source§impl Clone for ValidationWarning
impl Clone for ValidationWarning
Source§impl Debug for ValidationWarning
impl Debug for ValidationWarning
Source§impl Display for ValidationWarning
impl Display for ValidationWarning
Source§impl PartialEq for ValidationWarning
impl PartialEq for ValidationWarning
impl StructuralPartialEq for ValidationWarning
Auto Trait Implementations§
impl Freeze for ValidationWarning
impl RefUnwindSafe for ValidationWarning
impl Send for ValidationWarning
impl Sync for ValidationWarning
impl Unpin for ValidationWarning
impl UnsafeUnpin for ValidationWarning
impl UnwindSafe for ValidationWarning
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
ToCompactString::to_compact_string() Read moreSource§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
CompactString. Read more