• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
      • Theories
      • Rule-classes
      • Proof-builder
      • Recursion-and-induction
      • Hons-and-memoization
      • Events
      • Parallelism
      • History
      • Programming
        • Defun
        • Declare
        • System-utilities
          • Saving-event-data
          • Trans-eval
          • System-utilities-non-built-in
            • Pseudo-event-formp
            • Pseudo-event-form-listp
            • Directed-untranslate
            • Irrelevant-formals-info
            • Numbered-names
            • Context-message-pair
            • Prove$
            • Minimize-ruler-extenders
            • Paired-names
            • Orelse
            • Fresh-name-in-world-with-$s
            • Encapsulate-report-errors
            • On-failure
            • Chk-irrelevant-formals-ok
            • Named-formulas
              • Named-formulas-to-thm-events
              • Named-formula-to-thm-event
              • Prove-named-formulas
              • Prove-named-formula
              • Ensure-named-formulas
              • Pseudo-event-landmarkp
              • All-program-fns
              • All-logic-fns
              • Trans-eval-error-triple
              • Trans-eval-state
              • Pseudo-tests-and-callsp
              • User-interface
              • Pseudo-command-landmarkp
              • Pseudo-tests-and-calls-listp
              • Pseudo-command-formp
              • Orelse*
              • Identity-macro
            • Get-event-data
            • Untranslate
            • Constraint-info
          • Stobj
          • State
          • Mutual-recursion
          • Memoize
          • Mbe
          • Io
          • Defpkg
          • Apply$
          • Loop$
          • Programming-with-state
          • Arrays
          • Characters
          • Time$
          • Defconst
          • Fast-alists
          • Defmacro
          • Loop$-primer
          • Evaluation
          • Guard
          • Equality-variants
          • Compilation
          • Hons
          • ACL2-built-ins
          • Developers-guide
          • System-attachments
          • Advanced-features
          • Set-check-invariant-risk
          • Numbers
          • Efficiency
          • Irrelevant-formals
          • Introduction-to-programming-in-ACL2-for-those-who-know-lisp
          • Redefining-programs
          • Lists
          • Invariant-risk
          • Errors
          • Defabbrev
          • Conses
          • Alists
          • Set-register-invariant-risk
          • Strings
          • Program-wrapper
          • Get-internal-time
          • Basics
          • Packages
          • Oracle-eval
          • Defmacro-untouchable
          • <<
          • Primitive
          • Revert-world
          • Unmemoize
          • Set-duplicate-keys-action
          • Symbols
          • Def-list-constructor
          • Easy-simplify-term
          • Defiteration
          • Fake-oracle-eval
          • Defopen
          • Sleep
        • Operational-semantics
        • Real
        • Start-here
        • Miscellaneous
        • Output-controls
        • Bdd
        • Macros
        • Installation
        • Mailing-lists
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Named-formulas

    Ensure-named-formulas

    Cause a soft error if the proof of any named formula fails.

    Signature
    (ensure-named-formulas named-formulas named-hints 
                           verbose error-erp error-val ctx state) 
     
      → 
    (mv erp val state)
    Arguments
    named-formulas — Named formulas to prove (an alist from names to untranslated terms).
        Guard (symbol-alistp named-formulas).
    named-hints — Alist from names of formulas to proof hints to prove the formulas.
        Guard (symbol-truelist-alistp named-hints).
    verbose — Print progress messages or not.
        Guard (booleanp verbose).
    error-erp — Flag to return in case of error.
    error-val — Value to return in case of error.
    ctx — Context for errors.
    Returns
    erp — error-erp or nil.
    val — error-val or nil.

    Use the message from the named formula proof failure as error message.

    In case of error, use er-soft+ with the error flag and value passed as arguments.

    Definitions and Theorems

    Function: ensure-named-formulas

    (defun ensure-named-formulas
           (named-formulas named-hints
                           verbose error-erp error-val ctx state)
      (declare (xargs :stobjs (state)))
      (declare (xargs :guard (and (symbol-alistp named-formulas)
                                  (symbol-truelist-alistp named-hints)
                                  (booleanp verbose))))
      (let ((__function__ 'ensure-named-formulas))
        (declare (ignorable __function__))
        (b* (((mv success msg state)
              (prove-named-formulas named-formulas
                                    named-hints verbose state))
             ((unless success)
              (er-soft+ ctx error-erp error-val "~@0" msg)))
          (value nil))))