• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
      • B*
      • Defunc
      • Fty
        • Deftagsum
        • Defprod
        • Defflexsum
        • Defbitstruct
        • Deflist
        • Defalist
        • Defbyte
        • Deffixequiv
        • Defresult
        • Deffixtype
        • Defoption
        • Fty-discipline
        • Fold
        • Fty-extensions
        • Defsubtype
        • Defset
        • Deftypes
        • Specific-types
        • Defflatsum
        • Deflist-of-len
        • Defbytelist
        • Fty::basetypes
        • Defomap
        • Defvisitors
        • Deffixtype-alias
        • Deffixequiv-sk
        • Defunit
          • Defunit-implementation
            • Defunit-fn
            • Defunit-macro-definition
          • Multicase
          • Deffixequiv-mutual
          • Fty::baselists
          • Def-enumcase
          • Defmap
        • Apt
        • Std/util
        • Defdata
        • Defrstobj
        • Seq
        • Match-tree
        • Defrstobj
        • With-supporters
        • Def-partial-measure
        • Template-subst
        • Soft
        • Defthm-domain
        • Event-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
    • Defunit-implementation

    Defunit-macro-definition

    Definition of the defunit macro.

    Macro: defunit

    (defmacro defunit (type &key
                            value pred fix equiv parents short long)
     (cons
      'make-event
      (cons
       (cons
        'defunit-fn
        (cons
         (cons 'quote (cons type 'nil))
         (cons
            (cons 'quote (cons value 'nil))
            (cons (cons 'quote (cons pred 'nil))
                  (cons (cons 'quote (cons fix 'nil))
                        (cons (cons 'quote (cons equiv 'nil))
                              (cons (cons 'quote (cons parents 'nil))
                                    (cons short (cons long 'nil)))))))))
       'nil)))