• Top
    • Documentation
    • Books
    • Recursion-and-induction
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
      • Theories
      • Rule-classes
      • Proof-builder
      • Hons-and-memoization
      • Events
      • History
      • Parallelism
      • Programming
        • Defun
        • Declare
        • System-utilities
        • Stobj
        • State
        • Memoize
        • Mbe
        • Io
        • Defpkg
        • Apply$
        • Mutual-recursion
        • Loop$
        • Programming-with-state
        • Arrays
        • Characters
        • Time$
        • Loop$-primer
        • Fast-alists
        • Defmacro
        • Defconst
        • Evaluation
        • Guard
          • Verify-guards
          • Mbe
          • Set-guard-checking
          • Ec-call
          • Print-gv
          • Guards-and-evaluation
          • Guard-debug
          • Set-check-invariant-risk
          • Guard-evaluation-table
          • The
          • Guard-evaluation-examples-log
          • Guard-miscellany
          • Defthmg
          • Invariant-risk
          • With-guard-checking
          • Guard-holders
          • Guard-formula-utilities
          • Guard-example
          • Set-verify-guards-eagerness
          • Guard-quick-reference
          • Set-register-invariant-risk
          • Guards-for-specification
          • Guard-evaluation-examples-script
          • Guard-introduction
          • Non-exec
          • Set-guard-msg
          • Safe-mode
          • Set-print-gv-defaults
          • Guard-theorem-example
          • With-guard-checking-event
            • With-guard-checking-error-triple
            • Program-only
            • Guard-checking-inhibited
            • Extra-info
          • Equality-variants
          • Compilation
          • Hons
          • ACL2-built-ins
          • Developers-guide
          • System-attachments
          • Advanced-features
          • Set-check-invariant-risk
          • Numbers
          • Irrelevant-formals
          • Efficiency
          • 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
          • Defmacro-untouchable
          • Primitive
          • <<
          • Revert-world
          • Set-duplicate-keys-action
          • Unmemoize
          • Symbols
          • Def-list-constructor
          • Easy-simplify-term
          • Defiteration
          • Defopen
          • Sleep
        • Start-here
        • Real
        • Debugging
        • Miscellaneous
        • Output-controls
        • Macros
        • Interfacing-tools
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Testing-utilities
      • Math
    • Guard
    • ACL2-built-ins

    With-guard-checking-event

    Suppress or enable guard-checking for an event form

    See documentation on the closely related utility, with-guard-checking, for relevant background.

    General Forms:
    (with-guard-checking-event val form)
    (with-guard-checking-event (quote val) form)

    where val is a legal guard-checking value (see set-guard-checking, or evaluate *guard-checking-values* to see the list of such values), and form is a form that returns an error-triple, (mv erp val state). This macro is identical to with-guard-checking-error-triple, except that the first argument of a call of with-guard-checking-event must be a constant as described above, and it will generate a legal event form embedded-event-form. For example, the following (uninteresting) form may be placed in a book.

    (with-guard-checking-event
     :none
     (make-event (prog2$ (car 3) '(defun f (x) x))))

    In raw Lisp, (with-guard-checking-event x y) macroexpands to y; thus, wrapping an event with with-guard-checking-event has effect only inside the ACL2 read-eval-print loop. Because of that behavior, calls of with-guard-checking-event must not be used in function definitions; use with-guard-checking-error-triple in such cases.