Invalid rejection

The statement differs between program versions. Each verdict below belongs to the statement shown on its page.

Invalid rejection

Disproved
parse_number
Invalid rejection. Every nonempty byte slice that is not an unsigned numeric literal returns None.

View counterexample proof

Also proved for this program

Conditional theorem proved

The input byte slice has 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 assumptions
The accepted source arithmetic and bounded support establish this sharp uniform rejection boundary. The common invalid witness fails at the immediately following length 9223372036854120460, while realizing any such excluded witness requires one contiguous Rust byte-slice allocation of about 9.22 decimal exabytes (roughly 8 EiB), an exotic or possibly nonexistent hardware object rather than a present-day constructible counterexample.
Conditional theorem
theorem TrellisConditional_c0b964755dfba82a : ∀ (s : Aeneas.Std.Slice.{0} Aeneas.Std.U8),
  @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.SourceValidByteSlice s →
      @Ne.{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)
            s)
          (@List.nil.{0} Aeneas.Std.U8) →
        Not
            (@Exists.{1} dec2flt_model.DecimalLexeme fun (x : dec2flt_model.DecimalLexeme) =>
              And (@Eq.{1} (Option.{0} Bool) (dec2flt_model.DecimalLexeme.leadingSign x) (@Option.none.{0} Bool))
                (And (dec2flt_model.DecimalGoalVocabulary.validNumeric dec2flt_model.DecimalGoalVocabularyDefault x)
                  (@Eq.{1} (List.{0} Nat)
                    (dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault s)
                    (dec2flt_model.DecimalGoalVocabulary.renderNumeric dec2flt_model.DecimalGoalVocabularyDefault
                      x)))) →
          @Eq.{1} (Aeneas.Std.Result.{0} (Option.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal))
            (dec2flt_model.num.imp.dec2flt.parse.parse_number s)
            (@Aeneas.Std.Result.ok.{0} (Option.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal)
              (@Option.none.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal)) := by
TrellisConditional c0b964755dfba82a
The condition has an instance
theorem TrellisConditional_c0b964755dfba82a__ConditionInhabited : @Exists.{1} (Aeneas.Std.Slice.{0} Aeneas.Std.U8) fun (s : Aeneas.Std.Slice.{0} Aeneas.Std.U8) =>
  @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))) := by
TrellisConditional c0b964755dfba82a ConditionInhabited
The cited counterexample is excluded
theorem TrellisConditional_c0b964755dfba82a__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.Slice.{0} Aeneas.Std.U8)
          (fun (x : Aeneas.Std.Slice.{0} Aeneas.Std.U8) =>
            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)))) := by
TrellisConditional c0b964755dfba82a CounterexampleExcluded
Later revision · decision
NumberHelperRejection__Refutation uses the same arithmetic failure with a trailing x; it does not exhibit a successful acceptance of invalid syntax. The A condition permits keeping the existing order. All exponent digits must still be scanned after saturation and whole-input rejection must remain effective inside the domain, including non-UTF8 helper slices.
Definitions quoted from revised requirements

Conditional abstract composition

dec2flt
Conditional 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

dec2flt
Conditional 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)
More program dependencies (159)
Standard-library dependencies (39)

Related source and models come from the extraction records and declared dependencies.

Lean statement and supporting proof

Proposition checked for this verdict

theorem NumberHelperRejection__Refutation : Not
  (∀ (s : Aeneas.Std.Slice.{0} Aeneas.Std.U8),
    dec2flt_model.SourceValidByteSlice s →
      @Ne.{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)
            s)
          (@List.nil.{0} Aeneas.Std.U8) →
        Not
            (@Exists.{1} dec2flt_model.DecimalLexeme fun (x : dec2flt_model.DecimalLexeme) =>
              And (@Eq.{1} (Option.{0} Bool) (dec2flt_model.DecimalLexeme.leadingSign x) (@Option.none.{0} Bool))
                (And (dec2flt_model.DecimalGoalVocabulary.validNumeric dec2flt_model.DecimalGoalVocabularyDefault x)
                  (@Eq.{1} (List.{0} Nat)
                    (dec2flt_model.DecimalGoalVocabulary.bytes dec2flt_model.DecimalGoalVocabularyDefault s)
                    (dec2flt_model.DecimalGoalVocabulary.renderNumeric dec2flt_model.DecimalGoalVocabularyDefault
                      x)))) →
          @Eq.{1} (Aeneas.Std.Result.{0} (Option.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal))
            (dec2flt_model.num.imp.dec2flt.parse.parse_number s)
            (@Aeneas.Std.Result.ok.{0} (Option.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal)
              (@Option.none.{0} dec2flt_model.num.imp.dec2flt.decimal.Decimal))) := by

The negation is proved, disproving the requirement.

Alternate registered target · outside this verdict
theorem NumberHelperRejection :
    ∀ s : Slice Std.U8, SourceValidByteSlice s -> s.val ≠ [] ->
      (¬ ∃ x : DecimalLexeme, x.leadingSign = none ∧ DecimalGoalVocabularyDefault.validNumeric x ∧
        DecimalGoalVocabularyDefault.bytes s = DecimalGoalVocabularyDefault.renderNumeric x) ->
      num.imp.dec2flt.parse.parse_number s = ok none := by
Statement registration
Live polaritydisprove
Authorityrecorded audit polarity
Registered targetauthored:NumberHelperRejection__refutation
Closure nodes
  • NumberHelperRejection__Refutation
Counterexample argument as recorded · NumberHelperRejection__Refutation

Theorem

The following result is false: For every nonempty Rust byte slice that is not an unsigned numeric literal, parse_number returns normally with None.

Proof

Use the source-valid slice s supplied by InvalidOverflowBoundaryWitness. Its byte list is
[46]\mathbin{++}\operatorname{replicate}(9223372036854120450,49) \mathbin{++}[101,45,54,53,53,51,53,57,120].
The cited statement says that this slice is nonempty and that there is no valid numeric lexeme, with any leading sign, whose numeric rendering equals the bytes of s. In particular, there cannot be a valid numeric lexeme with no leading sign whose rendering is the bytes of s: if the target's unsigned-grammar existential supplied such a lexeme with the equality written as ``bytes equals rendering'', symmetry of equality would give precisely the rendering-equals-bytes witness excluded by the cited statement. Thus s satisfies the target's unsigned-grammar exclusion premise. The cited Boolean nonemptiness assertion is equivalent to the propositional inequality between the byte list and the empty list, so it also supplies the target's nonempty premise.
Suppose the displayed universal assertion were true and specialize it to this s. Source validity, propositional nonemptiness, and the unsigned exclusion just established would force parse_number(s) = ok None. But InvalidOverflowBoundaryWitness states instead that parse_number(s) = fail integerOverflow. Rewriting the forced equality by this witnessed parse result equates the distinct fail and ok constructors of the Aeneas Result type, an impossibility. Hence the universal assertion is false.
NumberHelperRejection Refutation
Recorded replacement requirements

number_helper_rejection

parse_number
Conditional invalid rejection. Every nonempty source-valid byte slice of length at most 3 EiB that is not an unsigned numeric literal returns normally with None, including executions with integer overflow checks enabled. The entire byte slice must be checked against the unsigned numeric grammar, including malformed exponent digits and trailing characters after exponent accumulation has stopped.
Compare requirement statements

Revised program

parse_number
Conditional invalid rejection. Every nonempty source-valid byte slice of length at most 3 EiB that is not an unsigned numeric literal returns normally with None, including executions with integer overflow checks enabled. The entire byte slice must be checked against the unsigned numeric grammar, including malformed exponent digits and trailing characters after exponent accumulation has stopped.

Read this version’s verdict and proof

Models and assumptions

Program assumptions and trust

These modeling choices occur in the declared dependencies of this requirement’s proofs.

All 32 entries