Invalid rejection
Disproveddec2fltInvalid rejection. Every string outside the numeric and special literal
grammar returns
Err.Also proved for this program
Conditional theorem provedThe input string has byte length at most ≈ 8 EiB.
The conditional theorem establishes the requirement within this domain. The unrestricted requirement keeps its own verdict above.
Read the conditional proof and assumptionsThe accepted source-arithmetic argument and
ParserInvalidRejectionSafeLength support the unchanged public invalid-rejection conclusion through this sharp uniform cutoff. InvalidOverflowBoundaryWitness is an invalid source string of the immediately following length 9223372036854120460 on which the public parser fails with checked integer overflow rather than returning Err. Realizing that excluded input requires one contiguous Rust string allocation of roughly 9.22 decimal exabytes (about 8 EiB), an exotic or possibly nonexistent hardware object rather than a present-day constructible counterexample.Conditional theorem
theorem TrellisConditional_dd99b8a97fe23649 : ∀ (s : Aeneas.Std.Str),
@LE.le.{0} Nat instLENat
(@List.length.{0} Aeneas.Std.U8
(@Subtype.val.{1} (List.{0} Aeneas.Std.U8)
(fun (l : List.{0} Aeneas.Std.U8) =>
@LE.le.{0} Nat instLENat (@List.length.{0} Aeneas.Std.U8 l) Aeneas.Std.Usize.max)
s))
(@OfNat.ofNat.{0} Nat (nat_lit 9223372036854120459) (instOfNatNat (nat_lit 9223372036854120459))) →
dec2flt_model.DecimalGoalVocabulary.sourceString dec2flt_model.DecimalGoalVocabularyDefault s →
dec2flt_model.DecimalGoalVocabulary.classifies dec2flt_model.DecimalGoalVocabularyDefault
(dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault s)
(@Option.none.{0} (Sum.{0, 0} dec2flt_model.DecimalLexeme (Prod.{0, 0} (Option.{0} Bool) Bool))) →
@Exists.{1} dec2flt_model.num.float_parse.ParseFloatError
fun (e : dec2flt_model.num.float_parse.ParseFloatError) =>
@Eq.{1}
(Aeneas.Std.Result.{0}
(Aeneas.Std.core.result.Result.{0, 0} dec2flt_model.F64 dec2flt_model.num.float_parse.ParseFloatError))
(@dec2flt_model.num.imp.dec2flt.dec2flt dec2flt_model.F64 Aeneas.Std.U64
dec2flt_model.F64.Insts.Dec2flt_modelNumImpDec2fltLemireU64 dec2flt_model.F64.Insts.CoreOpsArithDivF64F64
dec2flt_model.F64.Insts.CoreOpsArithMulF64F64 dec2flt_model.F64.Insts.CoreOpsArithNegF64 s)
(@Aeneas.Std.Result.ok.{0}
(Aeneas.Std.core.result.Result.{0, 0} dec2flt_model.F64 dec2flt_model.num.float_parse.ParseFloatError)
(@Aeneas.Std.core.result.Result.Err.{0, 0} dec2flt_model.F64 dec2flt_model.num.float_parse.ParseFloatError
e)) := byTrellisConditional dd99b8a97fe23649The condition has an instance
theorem TrellisConditional_dd99b8a97fe23649__ConditionInhabited : @Exists.{1} Aeneas.Std.Str fun (s : Aeneas.Std.Str) =>
@LE.le.{0} Nat instLENat
(@List.length.{0} Aeneas.Std.U8
(@Subtype.val.{1} (List.{0} Aeneas.Std.U8)
(fun (l : List.{0} Aeneas.Std.U8) =>
@LE.le.{0} Nat instLENat (@List.length.{0} Aeneas.Std.U8 l) Aeneas.Std.Usize.max)
s))
(@OfNat.ofNat.{0} Nat (nat_lit 9223372036854120459) (instOfNatNat (nat_lit 9223372036854120459))) := byTrellisConditional dd99b8a97fe23649 ConditionInhabitedThe cited counterexample is excluded
theorem TrellisConditional_dd99b8a97fe23649__CounterexampleExcluded : Not
(@LE.le.{0} Nat instLENat
(@List.length.{0} Aeneas.Std.U8
(@Subtype.val.{1} (List.{0} Aeneas.Std.U8)
(fun (l : List.{0} Aeneas.Std.U8) =>
@LE.le.{0} Nat instLENat (@List.length.{0} Aeneas.Std.U8 l) Aeneas.Std.Usize.max)
(@Classical.choose.{1} Aeneas.Std.Str
(fun (x : Aeneas.Std.Str) =>
And
(@Eq.{1} (List.{0} Aeneas.Std.U8)
(@Subtype.val.{1} (List.{0} Aeneas.Std.U8)
(fun (l : List.{0} Aeneas.Std.U8) =>
@LE.le.{0} Nat instLENat (@List.length.{0} Aeneas.Std.U8 l) Aeneas.Std.Usize.max)
x)
(@HAppend.hAppend.{0, 0, 0} (List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(@instHAppendOfAppend.{0} (List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(@List.instAppend.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)))
(@HAppend.hAppend.{0, 0, 0} (List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(@instHAppendOfAppend.{0} (List.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8))
(@List.instAppend.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 46) (instOfNatNat (nat_lit 46)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat (@OfNat.ofNat.{0} Nat (nat_lit 46) (instOfNatNat (nat_lit 46)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 46) (instOfNatNat (nat_lit 46)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 46) (instOfNatNat (nat_lit 46)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 46) (instOfNatNat (nat_lit 46)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.nil.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)))
(@List.replicate.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(@OfNat.ofNat.{0} Nat (nat_lit 9223372036854120450) (instOfNatNat (nat_lit 9223372036854120450)))
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 49) (instOfNatNat (nat_lit 49)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat (@OfNat.ofNat.{0} Nat (nat_lit 49) (instOfNatNat (nat_lit 49)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 49) (instOfNatNat (nat_lit 49)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 49) (instOfNatNat (nat_lit 49)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 49) (instOfNatNat (nat_lit 49)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 101) (instOfNatNat (nat_lit 101)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat (@OfNat.ofNat.{0} Nat (nat_lit 101) (instOfNatNat (nat_lit 101)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 101) (instOfNatNat (nat_lit 101)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 101) (instOfNatNat (nat_lit 101)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 101) (instOfNatNat (nat_lit 101)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 45) (instOfNatNat (nat_lit 45)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat (@OfNat.ofNat.{0} Nat (nat_lit 45) (instOfNatNat (nat_lit 45)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 45) (instOfNatNat (nat_lit 45)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 45) (instOfNatNat (nat_lit 45)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 45) (instOfNatNat (nat_lit 45)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 54) (instOfNatNat (nat_lit 54)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat (@OfNat.ofNat.{0} Nat (nat_lit 54) (instOfNatNat (nat_lit 54)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 54) (instOfNatNat (nat_lit 54)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 54) (instOfNatNat (nat_lit 54)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 54) (instOfNatNat (nat_lit 54)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 51) (instOfNatNat (nat_lit 51)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 51) (instOfNatNat (nat_lit 51)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 51) (instOfNatNat (nat_lit 51)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 51) (instOfNatNat (nat_lit 51)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 51) (instOfNatNat (nat_lit 51)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 53) (instOfNatNat (nat_lit 53)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat (@OfNat.ofNat.{0} Nat (nat_lit 57) (instOfNatNat (nat_lit 57)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 57) (instOfNatNat (nat_lit 57)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 57) (instOfNatNat (nat_lit 57)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 57) (instOfNatNat (nat_lit 57)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 57) (instOfNatNat (nat_lit 57)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.cons.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)
(Aeneas.Std.U8.ofNat
(@OfNat.ofNat.{0} Nat (nat_lit 120) (instOfNatNat (nat_lit 120)))
(@of_decide_eq_true
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 120) (instOfNatNat (nat_lit 120)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe (@OfNat.ofNat.{0} Nat (nat_lit 120) (instOfNatNat (nat_lit 120)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(@id.{0}
(@Eq.{1} Bool
(@Decidable.decide
(@LE.le.{0} Nat instLENat
(@OfNat.ofNat.{0} Nat (nat_lit 120) (instOfNatNat (nat_lit 120)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8))
(Nat.decLe
(@OfNat.ofNat.{0} Nat (nat_lit 120) (instOfNatNat (nat_lit 120)))
(Aeneas.Std.UScalar.cMax Aeneas.Std.UScalarTy.U8)))
Bool.true)
(@Eq.refl.{1} Bool Bool.true))))
(@List.nil.{0} (Aeneas.Std.UScalar Aeneas.Std.UScalarTy.U8)))))))))))))
(And
(@Eq.{1} Nat
(@List.length.{0} Aeneas.Std.U8
(@Subtype.val.{1} (List.{0} Aeneas.Std.U8)
(fun (l : List.{0} Aeneas.Std.U8) =>
@LE.le.{0} Nat instLENat (@List.length.{0} Aeneas.Std.U8 l) Aeneas.Std.Usize.max)
x))
(@OfNat.ofNat.{0} Nat (nat_lit 9223372036854120460) (instOfNatNat (nat_lit 9223372036854120460))))
(And (dec2flt_model.SourceValidByteSlice x)
(And (dec2flt_model.DecimalGoalVocabulary.sourceString dec2flt_model.DecimalGoalVocabularyDefault x)
(And
(@Eq.{1} Bool
(@bne.{0} (List.{0} Aeneas.Std.U8)
(@List.instBEq.{0} Aeneas.Std.U8 (@Aeneas.Std.instBEqUScalar_1 Aeneas.Std.UScalarTy.U8))
(@Subtype.val.{1} (List.{0} Aeneas.Std.U8)
(fun (l : List.{0} Aeneas.Std.U8) =>
@LE.le.{0} Nat instLENat (@List.length.{0} Aeneas.Std.U8 l) Aeneas.Std.Usize.max)
x)
(@List.nil.{0} Aeneas.Std.U8))
Bool.true)
(And
(Not
(@Exists.{1} dec2flt_model.DecimalLexeme fun (x_1 : dec2flt_model.DecimalLexeme) =>
And
(dec2flt_model.DecimalGoalVocabulary.validNumeric
dec2flt_model.DecimalGoalVocabularyDefault x_1)
(@Eq.{1} (List.{0} Nat)
(dec2flt_model.DecimalGoalVocabulary.renderNumeric
dec2flt_model.DecimalGoalVocabularyDefault x_1)
(dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault
x))))
(And
(Not
(@Exists.{1} (Option.{0} Bool) fun (sign : Option.{0} Bool) =>
@Exists.{1} Bool fun (nan : Bool) =>
dec2flt_model.DecimalGoalVocabulary.specialLiteral
dec2flt_model.DecimalGoalVocabularyDefault
(dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault
x)
sign nan))
(And
(dec2flt_model.DecimalGoalVocabulary.classifies dec2flt_model.DecimalGoalVocabularyDefault
(dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault x)
(@Option.none.{0}
(Sum.{0, 0} dec2flt_model.DecimalLexeme (Prod.{0, 0} (Option.{0} Bool) Bool))))
(And
(@Eq.{1}
(Aeneas.Std.Result.{0} (Option.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal))
(dec2flt_model.num.imp.dec2flt.parse.parse_number x)
(@Aeneas.Std.Result.fail.{0} (Option.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal)
Aeneas.Std.Error.integerOverflow))
(@Eq.{1}
(Aeneas.Std.Result.{0}
(Aeneas.Std.core.result.Result.{0, 0} dec2flt_model.F64
dec2flt_model.num.float_parse.ParseFloatError))
(@dec2flt_model.num.imp.dec2flt.dec2flt dec2flt_model.F64 Aeneas.Std.U64
dec2flt_model.F64.Insts.Dec2flt_modelNumImpDec2fltLemireU64
dec2flt_model.F64.Insts.CoreOpsArithDivF64F64
dec2flt_model.F64.Insts.CoreOpsArithMulF64F64
dec2flt_model.F64.Insts.CoreOpsArithNegF64 x)
(@Aeneas.Std.Result.fail.{0}
(Aeneas.Std.core.result.Result.{0, 0} dec2flt_model.F64
dec2flt_model.num.float_parse.ParseFloatError)
Aeneas.Std.Error.integerOverflow)))))))))))
dec2flt_model.InvalidOverflowBoundaryWitness)))
(@OfNat.ofNat.{0} Nat (nat_lit 9223372036854120459) (instOfNatNat (nat_lit 9223372036854120459)))) := byTrellisConditional dd99b8a97fe23649 CounterexampleExcludedLater revision · decision
ParserInvalidRejection__Refutation propagates the exabyte helper overflow on the invalid trailing-x witness. Keep normal Err on the complete unchanged grammar through A, with no whitespace, trailing-junk, UTF-8 or special-keyword relaxation. Exabyte inputs beyond A are not newly declared invalid by the mathematical classifier and are not promised normal rejection.
Definitions quoted from revised requirements
Conditional abstract composition
dec2fltConditional abstract composition. Let A = 3458764513820540928 bytes and B = 576460752303421440 bytes. The lexical and conversion component contracts admit implementations, with numeric lexical acceptance, rejection and record representation required for nonempty source-valid byte slices of length at most A, and preservation of the ordinary mathematical exact rounding target required for numeric inputs of length at most B. Special parsing, native correctness-or-defer, integer correctness-or-defer, unrestricted assembly, and the full-significand accumulated-exponent slow diagnostic retain their existing domains; the slow diagnostic applies to every source-valid unsigned numeric literal, without an A or B restriction. For any components satisfying these contracts, the dispatcher's normal results on Rust strings of byte length at most A satisfy classification, accumulated-exponent rounding and lexical sign requirements. On numeric strings of byte length at most B they additionally satisfy ordinary mathematical exact rounding. These conclusions include the native shortcut, integer tier, many-digit endpoint decision, fallback, sign handling and final assembly. Contract inhabitability and the existence of an abstract normal output for every Rust string of byte length at most A must be established, not inferred from an implication over an empty contract package.
Conditional component compliance
dec2fltConditional component compliance. Let A = 3458764513820540928 bytes and B = 576460752303421440 bytes. The actual source components satisfy the contracts used in conditional abstract composition. In particular, the numeric lexical component returns normally and satisfies acceptance, rejection and record representation on every nonempty source-valid byte slice of length at most A; it preserves the input's ordinary mathematical exact rounding target on numeric slices of length at most B. The source components for special parsing, native conversion, integer conversion and unrestricted assembly retain their existing full-domain obligations. The actual slow component satisfies the full-significand accumulated-exponent diagnostic on every source-valid unsigned numeric literal, without a length restriction. For every Rust string of byte length at most A, the concrete dispatcher agrees with the abstract component operations at its calls and establishes their helper preconditions. On numeric strings of byte length at most B, this agreement additionally preserves the exact rounding target throughout dispatch. These obligations include native shortcut, integer tier, many-digit decision, fallback, sign handling and assembly, and require a genuinely inhabited compatible component package.
Supporting proofs
Inspect related source (201)
- Dec2flt_modelNumImpDec2fltLemireU64 · dec2flt/mod.rs:217 Program Rust
- Dec2flt_modelNumImpTraitsFloatExtU64 · traits.rs:339 Program Rust
- biased_fp_to_float · dec2flt/mod.rs:282 Program Rust
More program dependencies (159)
- dec2flt · dec2flt/mod.rs:508 Program Rust
- dec2flt_with_trace · dec2flt/mod.rs:355 Program Rust
- try_fast_path · dec2flt/decimal.rs:59 Program Rust
- compute_float · dec2flt/lemire.rs:26 Program Rust
- parse_inf_nan · dec2flt/parse.rs:241 Program Rust
- parse_number · dec2flt/parse.rs:231 Program Rust
- parse_long_mantissa · dec2flt/slow.rs:27 Program Rust
- parse_long_mantissa_loop0 · dec2flt/slow.rs:51 Program Rust
- body · dec2flt/slow.rs:51 Program Rust
- parse_long_mantissa_loop1 · dec2flt/slow.rs:69 Program Rust
- body · dec2flt/slow.rs:69 Program Rust
- parse_long_mantissa_loop2 · dec2flt/slow.rs:94 Program Rust
- body · dec2flt/slow.rs:94 Program Rust
- MAX_EXPONENT_DISGUISED_FAST_PATH · dec2flt/mod.rs:220 Program Rust
- MAX_EXPONENT_FAST_PATH · dec2flt/mod.rs:219 Program Rust
- pow10_fast_path · dec2flt/mod.rs:222 Program Rust
- from_u64_bits · traits.rs:341 Program Rust
- integer_decode · traits.rs:348 Program Rust
- Dec2flt_modelNumImpTraitsFloatU64 · traits.rs:309 Program Rust
- offset_from · dec2flt/common.rs:30 Program Rust
- read_u64 · dec2flt/common.rs:18 Program Rust
- ParseFloatError · num/mod.rs:13 Program Rust
- Dec2FltTrace · dec2flt/mod.rs:295 Program Rust
- Lemire · dec2flt/mod.rs:115 Program Rust
- default · dec2flt/mod.rs:128 Program Rust
- default · dec2flt/mod.rs:121 Program Rust
- BiasedFp · dec2flt/common.rs:52 Program Rust
- eq · dec2flt/common.rs:51 Program Rust
- zero_pow2 · dec2flt/common.rs:62 Program Rust
- is_8digits · dec2flt/common.rs:40 Program Rust
- Decimal · dec2flt/decimal.rs:32 Program Rust
- can_use_fast_path · dec2flt/decimal.rs:42 Program Rust
- INT_POW10 · dec2flt/decimal.rs:8 Program Rust
- DecimalSeq · dec2flt/decimal_seq.rs:21 Program Rust
- DECIMAL_POINT_RANGE · dec2flt/decimal_seq.rs:67 Program Rust
- left_shift · dec2flt/decimal_seq.rs:129 Program Rust
- left_shift_loop0 · dec2flt/decimal_seq.rs:138 Program Rust
- body · dec2flt/decimal_seq.rs:138 Program Rust
- left_shift_loop1 · dec2flt/decimal_seq.rs:152 Program Rust
- body · dec2flt/decimal_seq.rs:152 Program Rust
- right_shift · dec2flt/decimal_seq.rs:175 Program Rust
- right_shift_loop0 · dec2flt/decimal_seq.rs:180 Program Rust
- body · dec2flt/decimal_seq.rs:180 Program Rust
- right_shift_loop0_loop0 · dec2flt/decimal_seq.rs:190 Program Rust
- body · dec2flt/decimal_seq.rs:190 Program Rust
- right_shift_loop1 · dec2flt/decimal_seq.rs:209 Program Rust
- body · dec2flt/decimal_seq.rs:209 Program Rust
- right_shift_loop2 · dec2flt/decimal_seq.rs:216 Program Rust
- body · dec2flt/decimal_seq.rs:216 Program Rust
- round · dec2flt/decimal_seq.rs:96 Program Rust
- round_loop · dec2flt/decimal_seq.rs:106 Program Rust
- body · dec2flt/decimal_seq.rs:106 Program Rust
- parse_decimal_seq · dec2flt/decimal_seq.rs:283 Program Rust
- parse_decimal_seq_loop0 · dec2flt/decimal_seq.rs:290 Program Rust
- body · dec2flt/decimal_seq.rs:290 Program Rust
- parse_decimal_seq_loop1 · dec2flt/decimal_seq.rs:361 Program Rust
- body · dec2flt/decimal_seq.rs:361 Program Rust
- parse_decimal_seq_loop2 · dec2flt/decimal_seq.rs:303 Program Rust
- body · dec2flt/decimal_seq.rs:303 Program Rust
- parse_decimal_seq_loop3 · dec2flt/decimal_seq.rs:307 Program Rust
- body · dec2flt/decimal_seq.rs:307 Program Rust
- parse_decimal_seq_loop4 · dec2flt/decimal_seq.rs:361 Program Rust
- body · dec2flt/decimal_seq.rs:361 Program Rust
- parse_decimal_seq_loop5 · dec2flt/decimal_seq.rs:307 Program Rust
- body · dec2flt/decimal_seq.rs:307 Program Rust
- parse_decimal_seq_loop6 · dec2flt/decimal_seq.rs:361 Program Rust
- body · dec2flt/decimal_seq.rs:361 Program Rust
- parse_decimal_seq_loop7 · dec2flt/decimal_seq.rs:361 Program Rust
- body · dec2flt/decimal_seq.rs:361 Program Rust
- set_precision · dec2flt/fpu.rs:99 Program Rust
- compute_product_approx · dec2flt/lemire.rs:134 Program Rust
- power · dec2flt/lemire.rs:121 Program Rust
- parse_8digits · dec2flt/parse.rs:18 Program Rust
- parse_partial_number · dec2flt/parse.rs:161 Program Rust
- parse_scientific · dec2flt/parse.rs:121 Program Rust
- parse_scientific_loop · dec2flt/parse.rs:142 Program Rust
- body · dec2flt/parse.rs:142 Program Rust
- try_parse_digits · dec2flt/parse.rs:30 Program Rust
- try_parse_digits_loop0 · dec2flt/parse.rs:33 Program Rust
- body · dec2flt/parse.rs:33 Program Rust
- try_parse_digits_loop1 · dec2flt/parse.rs:50 Program Rust
- body · dec2flt/parse.rs:50 Program Rust
- pfe_empty · dec2flt/mod.rs:270 Program Rust
- pfe_invalid · dec2flt/mod.rs:277 Program Rust
- MAX_SHIFT · dec2flt/slow.rs:28 Program Rust
- call · dec2flt/slow.rs:33 Program Rust
- Float · traits.rs:74 Program Rust
- FloatExt · traits.rs:170 Program Rust
- from_u64 · dec2flt/mod.rs:263 Program Rust
- BITS · traits.rs:319 Program Rust
- EXP_MASK · traits.rs:321 Program Rust
- INFINITY · traits.rs:312 Program Rust
- LARGEST_POWER_OF_TEN · traits.rs:327 Program Rust
- MAX_EXPONENT_ROUND_TO_EVEN · traits.rs:325 Program Rust
- MIN_EXPONENT_ROUND_TO_EVEN · traits.rs:324 Program Rust
- NAN · traits.rs:314 Program Rust
- NEG_INFINITY · traits.rs:313 Program Rust
- NEG_NAN · traits.rs:317 Program Rust
- SIG_MASK · traits.rs:322 Program Rust
- SIG_TOTAL_BITS · traits.rs:320 Program Rust
- SMALLEST_POWER_OF_TEN · traits.rs:328 Program Rust
- classify · traits.rs:334 Program Rust
- to_bits · traits.rs:330 Program Rust
- write_u64 · dec2flt/common.rs:25 Program Rust
- Dec2flt_modelNumImpTraitsInt · traits.rs:51 Program Rust
- FloatErrorKind · num/mod.rs:18 Program Rust
- Dec2FltAssemblyTrace · dec2flt/mod.rs:329 Program Rust
- ByteSlice · dec2flt/common.rs:4 Program Rust
- default · dec2flt/decimal_seq.rs:33 Program Rust
- MAX_DIGITS · dec2flt/decimal_seq.rs:63 Program Rust
- MAX_DIGITS_WITHOUT_OVERFLOW · dec2flt/decimal_seq.rs:66 Program Rust
- trim · dec2flt/decimal_seq.rs:82 Program Rust
- trim_loop · dec2flt/decimal_seq.rs:91 Program Rust
- body · dec2flt/decimal_seq.rs:91 Program Rust
- count_trailing_zeros · dec2flt/decimal_seq.rs:235 Program Rust
- count_trailing_zeros_loop · dec2flt/decimal_seq.rs:239 Program Rust
- body · dec2flt/decimal_seq.rs:239 Program Rust
- number_of_digits_decimal_left_shift · dec2flt/decimal_seq.rs:368 Program Rust
- number_of_digits_decimal_left_shift_loop · dec2flt/decimal_seq.rs:434 Program Rust
- body · dec2flt/decimal_seq.rs:434 Program Rust
- parse_decimal_exponent · dec2flt/decimal_seq.rs:269 Program Rust
- parse_decimal_exponent_loop · dec2flt/decimal_seq.rs:272 Program Rust
- body · dec2flt/decimal_seq.rs:272 Program Rust
- parse_digits_into_seq · dec2flt/decimal_seq.rs:256 Program Rust
- parse_digits_into_seq_loop · dec2flt/decimal_seq.rs:258 Program Rust
- body · dec2flt/decimal_seq.rs:258 Program Rust
- full_multiplication · dec2flt/lemire.rs:126 Program Rust
- adjust_many_digit_count · dec2flt/parse.rs:86 Program Rust
- adjust_many_digit_count_loop · dec2flt/parse.rs:89 Program Rust
- body · dec2flt/parse.rs:89 Program Rust
- MASK · dec2flt/parse.rs:19 Program Rust
- MUL1 · dec2flt/parse.rs:20 Program Rust
- MUL2 · dec2flt/parse.rs:21 Program Rust
- parse_many_digits · dec2flt/parse.rs:104 Program Rust
- NUM_POWERS · dec2flt/slow.rs:29 Program Rust
- POWERS · dec2flt/slow.rs:30 Program Rust
- closure · dec2flt/slow.rs:33 Program Rust
- LARGEST_POWER_OF_FIVE · dec2flt/table.rs:10 Program Rust
- POWER_OF_FIVE_128 · dec2flt/table.rs:19 Program Rust
- SMALLEST_POWER_OF_FIVE · dec2flt/table.rs:9 Program Rust
- CastInto · traits.rs:18 Program Rust
- default · traits.rs:116 Program Rust
- default · traits.rs:104 Program Rust
- default · traits.rs:119 Program Rust
- default · traits.rs:110 Program Rust
- default · traits.rs:113 Program Rust
- default · traits.rs:101 Program Rust
- Int · traits.rs:27 Program Rust
- Dec2flt_modelNumImpTraitsCastIntoI16 · traits.rs:45 Program Rust
- ONE · traits.rs:53 Program Rust
- ZERO · traits.rs:52 Program Rust
- try_add_digit · dec2flt/decimal_seq.rs:73 Program Rust
- TABLE · dec2flt/decimal_seq.rs:370 Program Rust
- TABLE_POW5 · dec2flt/decimal_seq.rs:379 Program Rust
- MIN_19DIGIT_INT · dec2flt/parse.rs:8 Program Rust
- try_parse_19digits · dec2flt/parse.rs:61 Program Rust
- try_parse_19digits_loop · dec2flt/parse.rs:64 Program Rust
- body · dec2flt/parse.rs:64 Program Rust
- cast · traits.rs:46 Program Rust
Standard-library dependencies (39)
- first · core/src/slice/mod.rs:155 Rust library
- as_bytes · core/src/str/mod.rs:498 Rust library
- clone · core/src/clone.rs:698 Rust library
- div · core/src/ops/arith.rs:515 Rust library
- mul · core/src/ops/arith.rs:350 Rust library
- neg · core/src/ops/arith.rs:719 Rust library
- bitand · core/src/ops/bit.rs:178 Rust library
- bitor · core/src/ops/bit.rs:282 Rust library
- shl · core/src/ops/bit.rs:489 Rust library
- shr · core/src/ops/bit.rs:612 Rust library
- EXPONENT_MASK · core/src/num/f64.rs:615 Rust library
- INFINITY · core/src/num/f64.rs:512 Rust library
- MANTISSA_DIGITS · core/src/num/f64.rs:412 Rust library
- MANTISSA_MASK · core/src/num/f64.rs:637 Rust library
- NAN · core/src/num/f64.rs:509 Rust library
- NEG_INFINITY · core/src/num/f64.rs:515 Rust library
- classify · core/src/num/f64.rs:782 Rust library
- from_bits · core/src/num/f64.rs:1269 Rust library
- to_bits · core/src/num/f64.rs:1223 Rust library
- is_ascii_digit · core/src/num/mod.rs:958 Rust library
- from_residual · core/src/option.rs:2793 Rust library
- branch · core/src/option.rs:2779 Rust library
- split_first · core/src/slice/mod.rs:198 Rust library
- CoreOpsArithDivF64F64 · core/src/ops/arith.rs:511 Rust library
- CoreOpsArithMulF64F64 · core/src/ops/arith.rs:344 Rust library
- CoreOpsArithNegF64 · core/src/ops/arith.rs:713 Rust library
- Div · core/src/ops/arith.rs:460 Rust library
- Mul · core/src/ops/arith.rs:322 Rust library
- Neg · core/src/ops/arith.rs:690 Rust library
- CoreMarkerCopy · core/src/marker.rs:57 Rust library
- FpCategory · core/src/num/mod.rs:1522 Rust library
- BitOr · core/src/ops/bit.rs:254 Rust library
- Shl · core/src/ops/bit.rs:461 Rust library
- Shr · core/src/ops/bit.rs:584 Rust library
- CoreCloneClone · core/src/clone.rs:696 Rust library
- CoreOpsBitBitAndU64U64 · core/src/ops/bit.rs:174 Rust library
- CoreOpsBitBitOrU64U64 · core/src/ops/bit.rs:278 Rust library
- CoreOpsBitShlU32U64 · core/src/ops/bit.rs:483 Rust library
- CoreOpsBitShrU32U64 · core/src/ops/bit.rs:606 Rust library
Related source and models come from the extraction records and declared dependencies.
Lean statement and supporting proof
Proposition checked for this verdict
theorem ParserInvalidRejection__Refutation : Not
(∀ (s : Aeneas.Std.Str),
dec2flt_model.DecimalGoalVocabulary.sourceString dec2flt_model.DecimalGoalVocabularyDefault s →
dec2flt_model.DecimalGoalVocabulary.classifies dec2flt_model.DecimalGoalVocabularyDefault
(dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault s)
(@Option.none.{0} (Sum.{0, 0} dec2flt_model.DecimalLexeme (Prod.{0, 0} (Option.{0} Bool) Bool))) →
@Exists.{1} dec2flt_model.num.float_parse.ParseFloatError
fun (e : dec2flt_model.num.float_parse.ParseFloatError) =>
@Eq.{1}
(Aeneas.Std.Result.{0}
(Aeneas.Std.core.result.Result.{0, 0} dec2flt_model.F64 dec2flt_model.num.float_parse.ParseFloatError))
(@dec2flt_model.num.imp.dec2flt.dec2flt dec2flt_model.F64 Aeneas.Std.U64
dec2flt_model.F64.Insts.Dec2flt_modelNumImpDec2fltLemireU64 dec2flt_model.F64.Insts.CoreOpsArithDivF64F64
dec2flt_model.F64.Insts.CoreOpsArithMulF64F64 dec2flt_model.F64.Insts.CoreOpsArithNegF64 s)
(@Aeneas.Std.Result.ok.{0}
(Aeneas.Std.core.result.Result.{0, 0} dec2flt_model.F64 dec2flt_model.num.float_parse.ParseFloatError)
(@Aeneas.Std.core.result.Result.Err.{0, 0} dec2flt_model.F64 dec2flt_model.num.float_parse.ParseFloatError
e))) := byThe negation is proved, disproving the requirement.
Alternate registered target · outside this verdict
theorem ParserInvalidRejection :
∀ s : Str, DecimalGoalVocabularyDefault.sourceString s -> DecimalGoalVocabularyDefault.classifies (DecimalGoalVocabularyDefault.bytes s) none ->
∃ e, num.imp.dec2flt.dec2flt F64.Insts.Dec2flt_modelNumImpDec2fltLemireU64
F64.Insts.CoreOpsArithDivF64F64 F64.Insts.CoreOpsArithMulF64F64
F64.Insts.CoreOpsArithNegF64 s = ok (core.result.Result.Err e) := byStatement registration
| Live polarity | disprove |
|---|---|
| Authority | recorded audit polarity |
| Registered target | authored:ParserInvalidRejection__refutation |
| Closure nodes |
|
Counterexample argument as recorded · ParserInvalidRejection__Refutation
Theorem
The following result is false:
For every source-valid Rust string classified as neither a numeric nor a special literal under the complete-input grammar, the extracted
f64 parser returns normally with Err.Proof
By InvalidOverflowBoundaryWitness, there is a source-valid Rust
string s whose bytes are a point, followed by
9223372036854120450 copies of the ASCII byte for
1, followed by
the bytes for e-655359x. The cited theorem states, in particular,
all three facts needed here: s satisfies the source-string predicate, the
complete-input grammar classifies its bytes as none, and the public
extracted binary64 specialization of dec2flt applied to s returns
fail integerOverflow.Suppose, for contradiction, that the displayed universal result were true.
Specializing it to this s, and applying its two premises using the
source-string and
none-classification facts above, would give an
error value e such that the same public extracted call returns normally as
ok (Err e). Rewriting that equality with the cited concrete failure
would equate fail integerOverflow with ok (Err e). These
are distinct constructors of the Aeneas Result type, so the equality
is impossible. This contradiction proves the exact negation.Recorded replacement requirements
parser_invalid_rejection
dec2fltConditional invalid rejection. Every Rust string of byte length at most 3 EiB that is outside the numeric and special literal grammar returns normally with
Err, without panicking, including executions with integer overflow checks enabled. Grammar matching covers the whole input, including characters after a numerically saturated exponent.