• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • ACL2
    • Macro-libraries
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
      • Sv
      • Fgl
      • Vwsim
      • Vl
        • Syntax
        • Loader
        • Warnings
        • Getting-started
        • Utilities
        • Printer
        • Kit
          • Vl-lint
            • Vl-lintconfig-p
            • Condcheck
            • Lint-warning-suppression
            • Lucid
              • Typo-detection
              • Vl-lucid-dissect-pair
              • Vl-lucidstate
              • Vl-lucid-dissect-var-main
              • Vl-lucidstate-init
              • Vl-lucid-check-uses-are-spurious-instances
              • Vl-hidslice-mark
              • Vl-namedarglist-lucidcheck
              • Vl-lucidst-mark-modport
              • Vl-lucid-multidrive-detect
              • Vl-namedarg-lucidcheck
              • Vl-lucid-filter-merges
              • Vl-hidsolo-mark
              • Vl-arguments-lucidcheck
              • Vl-lucid-dissect-database
              • Vl-design-lucid
              • Vl-maybe-delayoreventcontrol-lucidcheck
              • Vl-lucid-valid-bits-for-datatype
              • Vl-delayoreventcontrol-lucidcheck
              • Vl-repeateventcontrol-lucidcheck
              • Vl-namedparamvaluelist-lucidcheck
              • Vl-scopeexprlist-mark-solo
              • Vl-plainarg-lucidcheck
              • Vl-maybe-rhsexprlist-lucidcheck
              • Vl-maybe-paramvalue-lucidcheck
              • Vl-paramvaluelist-lucidcheck
              • Vl-namedparamvalue-lucidcheck
              • Vl-maybe-gatedelay-lucidcheck
              • Vl-plainarglist-lucidcheck
              • Vl-lucidstate-mark
              • Vl-lucid-mark-simple
              • Vl-eventcontrol-lucidcheck
              • Vl-enumitemlist-lucidcheck
              • Vl-delaycontrol-lucidcheck
              • Vl-paramvalue-lucidcheck
              • Vl-paramargs-lucidcheck
              • Vl-maybe-rhsexpr-lucidcheck
              • Vl-maybe-range-lucidcheck
              • Vl-lucid-typo-detect1
              • Vl-gatedelay-lucidcheck
              • Vl-evatomlist-lucidcheck
              • Vl-rangelist-lucidcheck
              • Vl-pps-lucidstate
              • Vl-enumitem-lucidcheck
              • Vl-custom-suppress-multidrive-p
              • Vl-evatom-lucidcheck
              • Vl-rhs-lucidcheck
              • Vl-range-lucidcheck
              • Vl-lucidocclist-drop-bad-modinsts
              • Vl-hidtrace-mark-interfaces
              • Vl-hidstep-mark-interfaces
              • Vl-add-typo-candidate
              • Vl-paramdecl-lucidcheck
              • Vl-interfaceportlist-lucidcheck
              • Vl-interfaceport-lucidcheck
              • Vl-fundecl-lucidcheck
              • Vl-design-lucidcheck-main
              • Vl-taskdecllist-lucidcheck
              • Vl-taskdecl-lucidcheck
              • Vl-portdecllist-lucidcheck
              • Vl-paramdecllist-lucidcheck
              • Vl-package-lucidcheck
              • Vl-modinst-lucidcheck
              • Vl-interfacelist-lucidcheck
              • Vl-gateinstlist-lucidcheck
              • Vl-dpiimportlist-lucidcheck
              • Vl-dpiexportlist-lucidcheck
              • Vl-vardecllist-lucidcheck
              • Vl-vardecl-lucidcheck
              • Vl-typedeflist-lucidcheck
              • Vl-portdecl-lucidcheck
              • Vl-packagelist-lucidcheck
              • Vl-modulelist-lucidcheck
              • Vl-modportlist-lucidcheck
              • Vl-modinstlist-lucidcheck
              • Vl-interface-lucidcheck
              • Vl-initiallist-lucidcheck
              • Vl-gateinst-lucidcheck
              • Vl-fundecllist-lucidcheck
              • Vl-dpiimport-lucidcheck
              • Vl-dpiexport-lucidcheck
              • Vl-assignlist-lucidcheck
              • Vl-alwayslist-lucidcheck
              • Vl-typedef-lucidcheck
              • Vl-modport-lucidcheck
              • Vl-initial-lucidcheck
              • Vl-finallist-lucidcheck
              • Vl-assign-lucidcheck
              • Vl-always-lucidcheck
              • Vl-aliaslist-lucidcheck
              • Vl-module-lucidcheck
              • Vl-lucid-typo-detect
              • Vl-final-lucidcheck
              • Vl-alias-lucidcheck
              • Vl-lucidocclist-drop-foreign-writes
              • Vl-lucid-pp-multibits
              • Vl-lucid-slices-append-bits
              • Vl-scopestack-is-portdecl-p
              • Vl-lucid-valid-bits-for-decl
              • Vl-lucid-resolved-slices->bits
              • Vl-lucid-resolved-slice->bits
              • Vl-lucid-instmod-find-port-dir
              • Vl-custom-suppress-multidrive-p-default
              • Vl-lucidmergealist-count
              • Vl-lucid-scopestack-subscope-p
              • Vl-lucid-range->bits
              • Vl-lucidocclist-drop-initials/finals
              • Vl-lucid-collect-solo-occs
              • Vl-lucid-collect-resolved-slices
              • Vl-basic-lucidctx
              • Vl-scopestack->flat-transitive-names-slow
              • Vl-lucidocclist-drop-generates
              • Vl-lucid-dissect
              • Vl-lucid-first-solo-occ
              • Vl-lucid-do-merges1
              • Vl-lucid-do-merges
              • Vl-lucidocclist-remove-tails
              • Vl-lucid-some-solo-occp
              • Vl-scopestack-top-level-name
              • Vl-normalize-scopestack
              • Vl-lucid-resolved-slice-p
              • Vl-lucid-all-slices-resolved-p
              • Vl-lucid-warning-type
              • Vl-lucid-plainarglist-nicely-resolved-p
              • Vl-lucid-multidrive-summary
              • Vl-string-expr->value
              • Vl-scopestack->topname
              • Vl-pp-lucid-multidrive-summary
              • Vl-lucid-all-slices-p
              • Vl-lucidocclist-some-transistory-p
              • Vl-lucidocc-transistory-p
              • Vl-lucid-plainarg-nicely-resolved-p
              • Vl-inside-true-generate-p
              • Vl-possible-typo-warnings
              • Vl-lucid-z-gateinst-p
              • Vl-lucid-modinst-nicely-resolved-p
              • Vl-inside-interface-p
              • Vl-inside-blockscope-p
              • Vl-typocandidates
                • Vl-typocandidates-p
                • Vl-typocandidates-fix
                  • Vl-typocandidates-equiv
                • Vl-lucid-z-expr-p
                • Vl-lucid-z-assign-p
                • Vl-lucidmergealist
                • Vl-lucid-summarize-bits
                • Vl-pp-merged-index-list
                • Vl-pp-merged-index
                • Vl-lucid-pp-bits
              • Lvaluecheck
              • Vl-interfacelist-alwaysstyle
              • Truncation-warnings
              • Vl-modulelist-alwaysstyle
              • Skip-detection
              • Vl-lint-report
              • Vl-lintresult
              • Vl::vl-design-sv-use-set
              • Oddexpr-check
              • Leftright-check
              • Duplicate-detect
              • Selfassigns
              • *vl-lint-help*
              • Arith-compare-check
              • Dupeinst-check
              • Qmarksize-check
              • Lint-whole-file-suppression
              • Run-vl-lint-main
              • Logicassign
              • Run-vl-lint
              • Vl-print-certain-warnings
              • Duperhs-check
              • Vl-lint-top
              • Sd-filter-problems
              • Vl-modulelist-add-svbad-warnings
              • Vl-module-add-svbad-warnings
              • Check-case
              • Vl-lint-extra-actions
              • Drop-lint-stubs
              • Vl-lint-print-warnings
              • Drop-user-submodules
              • Check-namespace
              • Vl-lintconfig-loadconfig
              • Vl-lint-design->svex-modalist-wrapper
              • Vl-delete-sd-problems-for-modnames-aux
              • Vl-collect-new-names-from-orignames
              • Vl-lint-print-all-warnings
              • Vl-design-remove-unnecessary-modules
              • Vl-delete-sd-problems-for-modnames
              • Vl-always-check-style
              • Vl-vardecllist-svbad-warnings
              • Vl-vardecl-svbad-warnings
              • Vl-reportcard-remove-suppressed
              • Vl-reportcard-keep-suppressed
              • Vl-alwayslist-check-style
              • Vl-remove-nameless-descriptions
              • Vl-lint-apply-quiet
              • Vl-warninglist-remove-suppressed
              • Vl-warninglist-keep-suppressed
              • Vl-print-eliminated-descs
              • Vl-module-alwaysstyle
              • Vl-jp-reportcard-aux
              • Vl-interface-alwaysstyle
              • Vl-design-alwaysstyle
              • Vl-jp-description-locations
              • Vl-jp-reportcard
              • Vl-pp-stringlist-lines
              • Vl-jp-design-locations
              • Vl-datatype-svbad-p
              • Unpacked-range-check
              • Sd-problem-major-p
              • Vl-alwaysstyle
            • Vl-server
            • Vl-gather
            • Vl-zip
            • Vl-main
            • Split-plusargs
            • Vl-shell
            • Vl-json
          • Mlib
          • Transforms
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Vl-typocandidates

    Vl-typocandidates-fix

    (vl-typocandidates-fix x) is an fty alist fixing function that follows the fix-keys strategy.

    Signature
    (vl-typocandidates-fix x) → fty::newx
    Arguments
    x — Guard (vl-typocandidates-p x).
    Returns
    fty::newx — Type (vl-typocandidates-p fty::newx).

    Note that in the execution this is just an inline identity function.

    Definitions and Theorems

    Function: vl-typocandidates-fix$inline

    (defun vl-typocandidates-fix$inline (x)
      (declare (xargs :guard (vl-typocandidates-p x)))
      (let ((__function__ 'vl-typocandidates-fix))
        (declare (ignorable __function__))
        (mbe :logic
             (if (atom x)
                 x
               (if (consp (car x))
                   (cons (cons (vl-scopestack-fix (caar x))
                               (string-list-fix (cdar x)))
                         (vl-typocandidates-fix (cdr x)))
                 (vl-typocandidates-fix (cdr x))))
             :exec x)))

    Theorem: vl-typocandidates-p-of-vl-typocandidates-fix

    (defthm vl-typocandidates-p-of-vl-typocandidates-fix
      (b* ((fty::newx (vl-typocandidates-fix$inline x)))
        (vl-typocandidates-p fty::newx))
      :rule-classes :rewrite)

    Theorem: vl-typocandidates-fix-when-vl-typocandidates-p

    (defthm vl-typocandidates-fix-when-vl-typocandidates-p
      (implies (vl-typocandidates-p x)
               (equal (vl-typocandidates-fix x) x)))

    Function: vl-typocandidates-equiv$inline

    (defun vl-typocandidates-equiv$inline (acl2::x acl2::y)
      (declare (xargs :guard (and (vl-typocandidates-p acl2::x)
                                  (vl-typocandidates-p acl2::y))))
      (equal (vl-typocandidates-fix acl2::x)
             (vl-typocandidates-fix acl2::y)))

    Theorem: vl-typocandidates-equiv-is-an-equivalence

    (defthm vl-typocandidates-equiv-is-an-equivalence
      (and (booleanp (vl-typocandidates-equiv x y))
           (vl-typocandidates-equiv x x)
           (implies (vl-typocandidates-equiv x y)
                    (vl-typocandidates-equiv y x))
           (implies (and (vl-typocandidates-equiv x y)
                         (vl-typocandidates-equiv y z))
                    (vl-typocandidates-equiv x z)))
      :rule-classes (:equivalence))

    Theorem: vl-typocandidates-equiv-implies-equal-vl-typocandidates-fix-1

    (defthm
          vl-typocandidates-equiv-implies-equal-vl-typocandidates-fix-1
      (implies (vl-typocandidates-equiv acl2::x x-equiv)
               (equal (vl-typocandidates-fix acl2::x)
                      (vl-typocandidates-fix x-equiv)))
      :rule-classes (:congruence))

    Theorem: vl-typocandidates-fix-under-vl-typocandidates-equiv

    (defthm vl-typocandidates-fix-under-vl-typocandidates-equiv
      (vl-typocandidates-equiv (vl-typocandidates-fix acl2::x)
                               acl2::x)
      :rule-classes (:rewrite :rewrite-quoted-constant))

    Theorem: equal-of-vl-typocandidates-fix-1-forward-to-vl-typocandidates-equiv

    (defthm
     equal-of-vl-typocandidates-fix-1-forward-to-vl-typocandidates-equiv
     (implies (equal (vl-typocandidates-fix acl2::x)
                     acl2::y)
              (vl-typocandidates-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)

    Theorem: equal-of-vl-typocandidates-fix-2-forward-to-vl-typocandidates-equiv

    (defthm
     equal-of-vl-typocandidates-fix-2-forward-to-vl-typocandidates-equiv
     (implies (equal acl2::x (vl-typocandidates-fix acl2::y))
              (vl-typocandidates-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)

    Theorem: vl-typocandidates-equiv-of-vl-typocandidates-fix-1-forward

    (defthm vl-typocandidates-equiv-of-vl-typocandidates-fix-1-forward
      (implies (vl-typocandidates-equiv (vl-typocandidates-fix acl2::x)
                                        acl2::y)
               (vl-typocandidates-equiv acl2::x acl2::y))
      :rule-classes :forward-chaining)

    Theorem: vl-typocandidates-equiv-of-vl-typocandidates-fix-2-forward

    (defthm vl-typocandidates-equiv-of-vl-typocandidates-fix-2-forward
     (implies
       (vl-typocandidates-equiv acl2::x (vl-typocandidates-fix acl2::y))
       (vl-typocandidates-equiv acl2::x acl2::y))
     :rule-classes :forward-chaining)

    Theorem: cons-of-vl-scopestack-fix-k-under-vl-typocandidates-equiv

    (defthm cons-of-vl-scopestack-fix-k-under-vl-typocandidates-equiv
      (vl-typocandidates-equiv (cons (cons (vl-scopestack-fix acl2::k)
                                           acl2::v)
                                     acl2::x)
                               (cons (cons acl2::k acl2::v) acl2::x)))

    Theorem: cons-vl-scopestack-equiv-congruence-on-k-under-vl-typocandidates-equiv

    (defthm
     cons-vl-scopestack-equiv-congruence-on-k-under-vl-typocandidates-equiv
     (implies
        (vl-scopestack-equiv acl2::k k-equiv)
        (vl-typocandidates-equiv (cons (cons acl2::k acl2::v) acl2::x)
                                 (cons (cons k-equiv acl2::v) acl2::x)))
     :rule-classes :congruence)

    Theorem: cons-of-string-list-fix-v-under-vl-typocandidates-equiv

    (defthm cons-of-string-list-fix-v-under-vl-typocandidates-equiv
      (vl-typocandidates-equiv
           (cons (cons acl2::k (string-list-fix acl2::v))
                 acl2::x)
           (cons (cons acl2::k acl2::v) acl2::x)))

    Theorem: cons-string-list-equiv-congruence-on-v-under-vl-typocandidates-equiv

    (defthm
     cons-string-list-equiv-congruence-on-v-under-vl-typocandidates-equiv
     (implies
        (str::string-list-equiv acl2::v v-equiv)
        (vl-typocandidates-equiv (cons (cons acl2::k acl2::v) acl2::x)
                                 (cons (cons acl2::k v-equiv) acl2::x)))
     :rule-classes :congruence)

    Theorem: cons-of-vl-typocandidates-fix-y-under-vl-typocandidates-equiv

    (defthm
          cons-of-vl-typocandidates-fix-y-under-vl-typocandidates-equiv
      (vl-typocandidates-equiv
           (cons acl2::x (vl-typocandidates-fix acl2::y))
           (cons acl2::x acl2::y)))

    Theorem: cons-vl-typocandidates-equiv-congruence-on-y-under-vl-typocandidates-equiv

    (defthm
     cons-vl-typocandidates-equiv-congruence-on-y-under-vl-typocandidates-equiv
     (implies (vl-typocandidates-equiv acl2::y y-equiv)
              (vl-typocandidates-equiv (cons acl2::x acl2::y)
                                       (cons acl2::x y-equiv)))
     :rule-classes :congruence)

    Theorem: vl-typocandidates-fix-of-acons

    (defthm vl-typocandidates-fix-of-acons
      (equal (vl-typocandidates-fix (cons (cons acl2::a acl2::b) x))
             (cons (cons (vl-scopestack-fix acl2::a)
                         (string-list-fix acl2::b))
                   (vl-typocandidates-fix x))))

    Theorem: vl-typocandidates-fix-of-append

    (defthm vl-typocandidates-fix-of-append
      (equal (vl-typocandidates-fix (append std::a std::b))
             (append (vl-typocandidates-fix std::a)
                     (vl-typocandidates-fix std::b))))

    Theorem: consp-car-of-vl-typocandidates-fix

    (defthm consp-car-of-vl-typocandidates-fix
      (equal (consp (car (vl-typocandidates-fix x)))
             (consp (vl-typocandidates-fix x))))