Typed2Computable's diagnostics — one named error variant per genuinely new restriction this
pass introduces beyond WellFormedness, plus a defense-in-depth catch-all for inputs that should
be unreachable by construction.
Which non-computable construct ComputableError.notComputable reports — the two
TypedTLAPlus.Expression constructors Core/ComputableTLAPlus/Syntax.lean has no counterpart
for: fnSet ([A -> B], the set of all functions from A to B) and recordSet ([a : A, ...], the set of all records shaped that way) — both denote sets with no finite runtime
representation.
- fnSet : NonComputableConstruct
[A -> B], the set of all functions fromAtoB. - recordSet : NonComputableConstruct
[a : A, ...], the set of all records shaped that way.
Instances For
Equations
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
Equations
- instBEqNonComputableConstruct.beq x✝ y✝ = (x✝.ctorIdx == y✝.ctorIdx)
Instances For
Equations
Typed2Computable's errors.
- notComputable
(pos : SourceSpan)
(construct : NonComputableConstruct)
: ComputableError
The algorithm references
fnSet/recordSet— genuinely not computable under this compiler's finite-sets assumption, and not enforced byWellFormedness(whose checks ban temporal/action operators and unbounded quantifiers, not these). - internalInvariantViolated
(pos : SourceSpan)
(description : String)
: ComputableError
Defense-in-depth: a construct
WellFormedness/Restrictions.lean's check 3 already guarantees can't be transitively-reachable-from-the-algorithm (an unboundedforall/exists/choosedomain, or a barefforall/eexists/stutter) still turned up, or a pending coercion (mvar) survived past the type checker's own output despiteCore/TypedTLAPlus/ Syntax.lean's own guarantee that none do. No proof of unreachability exists for any of these yet — just facts established by earlier passes — so this stays a runtime check, notabsurd/nomatch.
Instances For
Equations
- instReprComputableError = { reprPrec := instReprComputableError.repr }
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
Equations
Equations
- instBEqComputableError.beq (ComputableError.notComputable a a_1) (ComputableError.notComputable b b_1) = (a == b && a_1 == b_1)
- instBEqComputableError.beq (ComputableError.internalInvariantViolated a a_1) (ComputableError.internalInvariantViolated b b_1) = (a == b && a_1 == b_1)
- instBEqComputableError.beq x✝¹ x✝ = false
Instances For
Equations
- One or more equations did not get rendered due to their size.