pub enum SafetyCondition {
NoInstances {
type_id: TypeId,
include_subtypes: bool,
},
OwnsMinimum {
owns: OwnsFactId,
minimum: u64,
},
OwnsMaximum {
owns: OwnsFactId,
maximum: u64,
},
RangeLower {
subject: ScalarSafetySubject,
lower: CanonicalValue,
},
RangeUpper {
subject: ScalarSafetySubject,
upper: CanonicalValue,
},
ValuesNarrowed {
subject: ScalarSafetySubject,
allowed: Vec<CanonicalValue>,
},
NoOrphanAttributes {
attribute: AttributeId,
},
Unresolvable {
reason: UnresolvableSafetyReason,
unlock: SafetyConditionUnlock,
},
}Expand description
Closed verifier-derived safety-condition vocabulary.
Variants§
NoInstances
No instance of a type may exist.
Fields
OwnsMinimum
Every owner must have at least the target number of attributes.
Fields
owns: OwnsFactIdExact effective ownership being tightened.
OwnsMaximum
No owner may have more than the target number of distinct attribute values.
Fields
owns: OwnsFactIdExact effective ownership being tightened.
RangeLower
Existing values must not be below a target lower bound.
Fields
subject: ScalarSafetySubjectExact scalar subject being constrained.
lower: CanonicalValueInclusive target lower bound.
RangeUpper
Existing values must not be above a target upper bound.
Fields
subject: ScalarSafetySubjectExact scalar subject being constrained.
upper: CanonicalValueInclusive target upper bound.
ValuesNarrowed
Existing values must belong to the target allowed-value set.
Fields
subject: ScalarSafetySubjectExact scalar subject being constrained.
allowed: Vec<CanonicalValue>Canonically ordered, non-empty target allowed values.
NoOrphanAttributes
No attribute instance may be orphaned when @independent is removed.
Fields
attribute: AttributeIdAttribute type losing independent existence.
Unresolvable
The verifier identified a requirement that cannot be silently weakened.
Fields
reason: UnresolvableSafetyReasonStable explanation of the missing representation.
unlock: SafetyConditionUnlockFeature or workflow which can unlock the transition.
Implementations§
Source§impl SafetyCondition
impl SafetyCondition
Sourcepub const fn is_resolvable(&self) -> bool
pub const fn is_resolvable(&self) -> bool
Return whether the current assertion algebra can lower this condition.
Sourcepub const fn unlock(&self) -> Option<SafetyConditionUnlock>
pub const fn unlock(&self) -> Option<SafetyConditionUnlock>
Return an explicit missing feature or workflow, when gated.