• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • Std
    • Proof-automation
    • Macro-libraries
      • B*
      • Defunc
      • Fty
      • Apt
      • Std/util
      • Defdata
      • Defrstobj
      • Seq
      • Match-tree
      • Defrstobj
      • With-supporters
      • Def-partial-measure
      • Template-subst
      • Soft
      • Defthm-domain
      • Event-macros
        • Evmac-input-hints-p
        • Evmac-input-print-p
        • Event-macro-input-processing
        • Function-definedness
        • Event-macro-screen-printing
        • Make-event-terse
        • Event-macro-applicability-conditions
        • Event-macro-results
        • Template-generators
        • Event-macro-event-generators
        • Event-macro-proof-preparation
        • Try-event
        • Restore-output?
        • Restore-output
        • Fail-event
        • Cw-event
        • Event-macro-xdoc-constructors
          • Event-macro-xdoc-constructors-user-level
            • Xdoc::evmac-desc-function/lambda/macro
            • Xdoc::evmac-desc-term
            • Xdoc::evmac-topic-design-notes
            • Xdoc::evmac-appcond
              • Xdoc::evmac-desc-input-name
              • Xdoc::evmac-section-redundancy
              • Xdoc::evmac-input-show-only
              • Xdoc::evmac-input-print
              • Xdoc::evmac-desc-input-enable-t/nil
              • Xdoc::evmac-section-appconds
              • Xdoc::evmac-input-hints
              • Xdoc::evmac-section-generated
              • Xdoc::evmac-section-intro
              • Xdoc::evmac-section-inputs
              • Xdoc::evmac-section-form
            • Event-macro-xdoc-constructors-implementation-level
          • Event-macro-intro-macros
        • Def-universal-equiv
        • Def-saved-obligs
        • With-supporters-after
        • Definec
        • Sig
        • Outer-local
        • Data-structures
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Event-macro-xdoc-constructors-user-level

    Xdoc::evmac-appcond

    Construct an applicability condition description in the user documentation of an event macro.

    This generates an xdoc::desc.

    The name input must be a string that names the applicability condition.

    The main input must be an XDOC tree that contains the main description of the applicability condition, consisting of explanatory natural language and formal code for the formula(s).

    The design-notes and design-notes-appcond inputs must be either both present or both absent. If present, they must be both XDOC trees: the first one references the design notes of the event macro (which usually includes a link to the design notes); the second one provides the name of the applicability condition (usually some mathematical notation) used in the design notes. If these two inputs are present, the generated XDOC includes text relating the applicability condition to the design notes.

    If the presence input is present, it must be an XDOC tree. In this case, the generated XDOC includes text explaining that the applicability condition is present under the condition described by the presence input.

    Macro: evmac-appcond

    (defmacro xdoc::evmac-appcond (name main &key design-notes
                                        design-notes-appcond presence)
     (declare (xargs :guard (stringp name)))
     (cons
      'xdoc::desc
      (cons
       (concatenate 'string "@('" name "')")
       (cons
        main
        (append
         (and
            design-notes design-notes-appcond
            (cons (cons 'xdoc::p
                        (cons '"This corresponds to "
                              (cons design-notes-appcond
                                    (cons '" in the "
                                          (cons design-notes '("."))))))
                  'nil))
         (and
          presence
          (cons
           (cons
            'xdoc::p
            (cons
              '"This applicability condition is present if and only if "
              (cons presence '("."))))
           'nil)))))))