• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
        • Crypto-hdwallet
        • Apt
        • Error-checking
        • Fty-extensions
        • Isar
        • Kestrel-utilities
        • Set
        • C
          • Syntax-for-tools
          • Atc
          • Transformation-tools
            • Simpadd0
            • Proof-generation
            • Split-gso
            • Wrap-fn
            • Constant-propagation
            • Specialize
            • Split-fn
            • Split-fn-when
            • Split-all-gso
            • Copy-fn
            • Variables-in-computation-states
            • Rename
            • Utilities
              • Free-vars
              • Abstract-syntax-rename-fn
              • Call-graphs
                • Qualified-ident
                • Call-graph-transitive-closure
                • Qualified-ident-option
                  • Qualified-ident-option-fix
                  • Qualified-ident-option-equiv
                  • Qualified-ident-option-case
                    • Qualified-ident-option-some
                    • Qualified-ident-option-none
                    • Qualified-ident-optionp
                  • Call-graph-transitive-closure0
                  • Call-graph-init-declor-list
                  • Call-graph-fundef
                  • Call-graph-statassert
                  • Call-graph-init-declor
                  • Call-graph-declon
                  • Call-graph-const-expr
                  • Call-graph-transunit
                  • Call-graph-ext-declon-list
                  • Call-graph-ext-declon
                  • Call-graph-update
                  • Qualify-ident
                  • Exists-call-pathp
                  • Uncertain-call-pathp
                  • Recursivep
                  • Direct-recursivep
                  • Call-graph-filepath-transunit-map
                  • Call-graph-transunit-ensemble
                  • Call-graph
                  • Qualified-ident-option-set
                  • Direct-fun-refp
                • Fresh-ident-utility
                • Collect-idents
                • Subst-free
              • Proof-generation-theorems
              • Input-processing
            • Language
            • Representation
            • Insertion-sort
            • Pack
          • Soft
          • Bv
          • Imp-language
          • Ethereum
          • Event-macros
          • Java
          • Riscv
          • Bitcoin
          • Zcash
          • Yul
          • ACL2-programming-language
          • Prime-fields
          • Json
          • Syntheto
          • File-io-light
          • Cryptography
          • Number-theory
          • Axe
          • Lists-light
          • Builtins
          • Solidity
          • Helpers
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Axe
        • Execloader
      • Math
      • Testing-utilities
    • Qualified-ident-option

    Qualified-ident-option-case

    Case macro for the different kinds of qualified-ident-option structures.

    This is an ACL2::fty sum-type case macro, typically introduced by fty::defflexsum or fty::deftagsum. It allows you to safely check the type of a qualified-ident-option structure, or to split into cases based on its type.

    Short Form

    In its short form, qualified-ident-option-case allows you to safely check the type of a qualified-ident-option structure. For example:

    (qualified-ident-option-case x :none)

    can be used to determine whether x is a none instead of some other kind of qualified-ident-option structure.

    Long Form

    In its longer form, qualified-ident-option-case allows you to split into cases based on the kind of structure you are looking at. A typical example would be:

    (qualified-ident-option-case x
      :none ...
      :some ...)

    It is also possible to consolidate ``uninteresting'' cases using :otherwise.

    For convenience, the case macro automatically binds the fields of x for you, as appropriate for each case. That is, in the :none case, you can use fty::defprod-style foo.bar style accessors for x without having to explicitly add a none b* binder.