TrellisConditional_dd99b8a97fe23649

Lean checked

Statement

This explanation was written alongside the formalization to describe the statement and its reasoning.

Theorem

Kernel-sealed conditional obligation for authored:ParserInvalidRejection.

Lean statement

Trellis authored these statements and proofs. Lean checks the formal proofs; the assumptions used by each proof are listed below.

import Tablet.DecimalGoalVocabularyDefault
import Tablet.F64_Insts_Dec2flt_modelNumImpDec2fltLemireU64
import Tablet.F64_Insts_CoreOpsArithDivF64F64
import Tablet.F64_Insts_CoreOpsArithMulF64F64
import Tablet.F64_Insts_CoreOpsArithNegF64
import Tablet.F64_Insts_Dec2flt_modelNumImpTraitsFloatExtU64
import Tablet.num_imp_dec2flt_dec2flt
import Tablet.num_imp_dec2flt_dec2flt_with_trace
import Tablet.num_imp_dec2flt_parse_parse_number
import Tablet.num_imp_dec2flt_parse_parse_inf_nan
import Tablet.num_imp_dec2flt_decimal_Decimal_try_fast_path
import Tablet.num_imp_dec2flt_lemire_compute_float
import Tablet.num_imp_dec2flt_slow_parse_long_mantissa
import Tablet.num_imp_dec2flt_biased_fp_to_float
import Tablet.InvalidOverflowBoundaryWitness
import Tablet.ParserInvalidRejectionSafeLength

open Aeneas Aeneas.Std Result ControlFlow Error
set_option autoImplicit false

namespace dec2flt_model

-- [TABLET NODE: TrellisConditional_dd99b8a97fe23649]
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)) := by
Proof

Natural-language proof

The status above describes the Lean proof. Its explanatory prose may remain a sketch after that proof closes.

Explanatory prose status

Prose proof: SKETCH. The explanatory prose is preserved as it stood when captured.

Earlier prose review

An earlier review questioned the prose argument. Lean subsequently checked the formal proof. Review of the statement’s intended meaning is a separate judgment.

Proof

SKETCH:

Lean proof


  intro s hlen hsource hclass
  exact ParserInvalidRejectionSafeLength s hsource hlen hclass

Download Lean source · Download TeX source

Complete Lean module
import Tablet.DecimalGoalVocabularyDefault
import Tablet.F64_Insts_Dec2flt_modelNumImpDec2fltLemireU64
import Tablet.F64_Insts_CoreOpsArithDivF64F64
import Tablet.F64_Insts_CoreOpsArithMulF64F64
import Tablet.F64_Insts_CoreOpsArithNegF64
import Tablet.F64_Insts_Dec2flt_modelNumImpTraitsFloatExtU64
import Tablet.num_imp_dec2flt_dec2flt
import Tablet.num_imp_dec2flt_dec2flt_with_trace
import Tablet.num_imp_dec2flt_parse_parse_number
import Tablet.num_imp_dec2flt_parse_parse_inf_nan
import Tablet.num_imp_dec2flt_decimal_Decimal_try_fast_path
import Tablet.num_imp_dec2flt_lemire_compute_float
import Tablet.num_imp_dec2flt_slow_parse_long_mantissa
import Tablet.num_imp_dec2flt_biased_fp_to_float
import Tablet.InvalidOverflowBoundaryWitness
import Tablet.ParserInvalidRejectionSafeLength

open Aeneas Aeneas.Std Result ControlFlow Error
set_option autoImplicit false

namespace dec2flt_model

-- [TABLET NODE: TrellisConditional_dd99b8a97fe23649]
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)) := by
-- BODY
  intro s hlen hsource hclass
  exact ParserInvalidRejectionSafeLength s hsource hlen hclass

Proof structure

Follow the declared dependencies to read the supporting statements and proofs.

Explore this dependency tree

Inspect related source (201)
More program dependencies (159)
Standard-library dependencies (39)

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

Proof assumptions and review

Lean checks the formal proof. Trellis also reviews how the statement corresponds to the intended requirement.

Transitive assumptions

This list combines the assumptions recorded for this declaration and its dependencies. It may include assumptions used by auxiliary declarations in those modules.

Helper theorems included
All 167 entries
Technical checking records
Local closure summary
{
  "node": "TrellisConditional_dd99b8a97fe23649",
  "closure_version": "patch_c_v1",
  "active_decl_hash": "d296996dc5b10e930e3c044d4518bbc38681236875c88d77ebec3b85a2095b7e",
  "active_statement_hash": "74e44b4a1b7a3f71c2f004d4e5ccb448e13eb072dfa41299d3ccca946be38f9f",
  "kernel_axioms": [
    "propext"
  ],
  "toolchain_hash": "ce4c4e3d87434b9663f46de25ce34b48a0cf0d392e0a320a0787b4674a2d7b61",
  "lean_executable_hash": "3e0d0d3d801675359f2d4cf9815bfdb417b20b92fdd9d48b3b14c95bbae28bbf",
  "checker_script_hash": "c8e4a03273e23b9a8f2e141020652a4e0b7b0a8ab0883366ea9d031ca3f37aa1",
  "approved_axioms_hash": "ab64d13f256386ee0e494a5abcc6a5db49512cf3d90bbdfcabd6327793a31f95",
  "axcheck_status": "Agreed",
  "accepted_at_snapshot_id": "worker-result-local-closure-issuance-cycle-118",
  "boundary_theorems": {},
  "strict_theorem_deps": {
    "ParserInvalidRejectionSafeLength": "845b1541b90b352a"
  },
  "strict_definition_deps": {
    "DecimalGoalVocabulary": "65227461bf3cac06",
    "DecimalGoalVocabularyDefault": "512f8d0aea894250",
    "DecimalLexeme": "c43614ff2149ecf2",
    "F64": "ec4e25fbaf4e11d4",
    "F64_Insts_CoreOpsArithDivF64F64": "dc44e13a99fc6bed",
    "F64_Insts_CoreOpsArithMulF64F64": "1ae1a9021a654abd",
    "F64_Insts_CoreOpsArithNegF64": "2d9be310c546ea2e",
    "F64_Insts_Dec2flt_modelNumImpDec2fltLemireU64": "30963b4ef656cc79",
    "num_float_parse_ParseFloatError": "c43614ff2149ecf2",
    "num_imp_dec2flt_dec2flt": "f9f7d93449a25efa"
  }
}
Prose assessment
{
  "label": "Sound flag superseded by recorded Lean closure",
  "assessment_status": "ReviewerPinnedFail",
  "fingerprint_relation": "matches current fingerprint",
  "assessment_fingerprint": "sound-v2:8949a38aacb51a1e138af2d9c8bffbc0670e08780b336e4188697e41099412bb",
  "current_fingerprint": "sound-v2:8949a38aacb51a1e138af2d9c8bffbc0670e08780b336e4188697e41099412bb",
  "superseded_for_theorem_closure": true
}
Review verdicts
{
  "corr_status": "Pass",
  "sound_status": "Fail",
  "substantiveness_status": "Pass"
}