• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • ACL2
    • Macro-libraries
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
        • Crypto-hdwallet
        • Apt
          • Simplify-defun
          • Isodata
          • Tailrec
          • Schemalg
            • Schemalg-implementation
              • Schemalg-event-generation
              • Schemalg-fn
              • Schemalg-macro-definition
              • Schemalg-input-processing
                • Schemalg-process-inputs
                • Schemalg-process-schema-inputs
                • Schemalg-process-divconq-list-0-1-2-inputs
                • Schemalg-process-divconq-oset-0-1-inputs
                • Schemalg-process-divconq-list-0-1-inputs
                • Schemalg-process-algo-name
                  • Schemalg-process-oset-input
                  • Schemalg-process-list-input
                  • Schemalg-check-allowed-input
                  • Schemalg-process-tail-output
                  • Schemalg-process-cdr-output
                  • Schemalg-process-spec-2-name
                  • Schemalg-process-spec-1-name
                  • Schemalg-process-spec-0-name
                  • Schemalg-process-equal-algo-name
                  • Schemalg-process-fvar-2-name
                  • Schemalg-process-fvar-1-name
                  • Schemalg-process-fvar-0-name
                  • Schemalg-process-schema
                  • Schemalg-process-algo-name-aux
                  • *schemalg-schemas*
              • Schemalg-divconq-oset-0-1
              • Schemalg-divconq-list-0-1
            • Restrict
            • Expdata
            • Casesplit
            • Simplify-term
            • Simplify-defun-sk
            • Parteval
            • Solve
            • Wrap-output
            • Propagate-iso
            • Simplify
            • Finite-difference
            • Drop-irrelevant-params
            • Copy-function
            • Lift-iso
            • Rename-params
            • Utilities
            • Simplify-term-programmatic
            • Simplify-defun-sk-programmatic
            • Simplify-defun-programmatic
            • Simplify-defun+
            • Common-options
            • Common-concepts
          • Error-checking
          • Fty-extensions
          • Isar
          • Kestrel-utilities
          • Set
          • Soft
          • C
          • Bv
          • Imp-language
          • Event-macros
          • Java
          • Bitcoin
          • Ethereum
          • Yul
          • Zcash
          • ACL2-programming-language
          • Prime-fields
          • Json
          • Syntheto
          • File-io-light
          • Cryptography
          • Number-theory
          • Lists-light
          • Axe
          • Builtins
          • Solidity
          • Helpers
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Axe
        • Execloader
      • Math
      • Testing-utilities
    • Schemalg-input-processing

    Schemalg-process-algo-name

    Process the :algo-name input.

    Signature
    (schemalg-process-algo-name algo-name ?f ?f1...?fp 
                                acl2::names-to-avoid ctx state) 
     
      → 
    (mv acl2::erp acl2::result state)
    Arguments
    ?f — Guard (symbolp ?f).
    ?f1...?fp — Guard (symbol-listp ?f1...?fp).
    acl2::names-to-avoid — Guard (symbol-listp acl2::names-to-avoid).
    Returns
    acl2::result — A (tuple (fn symbolp) (updated-names-to-avoid symbol-listp) result).

    Definitions and Theorems

    Function: schemalg-process-algo-name-aux

    (defun schemalg-process-algo-name-aux (?f1...?fp)
     (declare (xargs :guard (symbol-listp ?f1...?fp)))
     (let ((__function__ 'schemalg-process-algo-name-aux))
      (declare (ignorable __function__))
      (cond
        ((endp ?f1...?fp) nil)
        (t (append (list #\[)
                   (explode (symbol-name (car ?f1...?fp)))
                   (list #\])
                   (schemalg-process-algo-name-aux (cdr ?f1...?fp)))))))

    Function: schemalg-process-algo-name

    (defun schemalg-process-algo-name
           (algo-name ?f ?f1...?fp
                      acl2::names-to-avoid ctx state)
     (declare (xargs :stobjs (state)))
     (declare (xargs :guard (and (symbolp ?f)
                                 (symbol-listp ?f1...?fp)
                                 (symbol-listp acl2::names-to-avoid))))
     (let ((__function__ 'schemalg-process-algo-name))
      (declare (ignorable __function__))
      (b*
       (((er &)
         (ensure-value-is-symbol$ algo-name
                                  (msg "The ~x0 input" :algo-name)
                                  t nil))
        (acl2::fn
            (if (eq algo-name :auto)
                (b* ((??f-chars (explode (symbol-name ?f)))
                     (algo-chars (if (and (consp ?f-chars)
                                          (eql (car ?f-chars) #\?))
                                     (cdr ?f-chars)
                                   ?f-chars))
                     ([?f1]...[?fp]-chars
                          (schemalg-process-algo-name-aux ?f1...?fp)))
                  (intern-in-package-of-symbol
                       (implode (append algo-chars [?f1]...[?fp]-chars))
                       ?f))
              algo-name))
        ((er acl2::names-to-avoid)
         (ensure-symbol-is-fresh-event-name$
          acl2::fn
          (msg
           "The name ~x0 specified (perhaps by default) by the ~x1 input"
           acl2::fn :algo-name)
          'function
          acl2::names-to-avoid t nil)))
       (value (list acl2::fn acl2::names-to-avoid)))))