• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Community
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
        • Warnings
        • Primitives
        • Use-set
        • Syntax
        • Getting-started
        • Utilities
        • Loader
        • Transforms
        • Lint
        • Mlib
          • Scopestack
          • Filtering-by-name
          • Vl-namefactory
          • Substitution
          • Allexprs
          • Hid-tools
          • Vl-consteval
          • Range-tools
          • Lvalexprs
          • Hierarchy
          • Finding-by-name
          • Expr-tools
          • Expr-slicing
          • Stripping-functions
            • Vl-plainarglist-strip
            • Vl-namedarglist-strip
              • Vl-gateinstlist-strip
              • Vl-modinstlist-strip
              • Vl-assignlist-strip
              • Vl-rangelist-strip
              • Vl-expr-strip
              • Vl-atom-strip
              • Vl-gateinst-strip
              • Vl-plainarg-strip
              • Vl-namedarg-strip
              • Vl-modinst-strip
              • Vl-assign-strip
              • Vl-arguments-strip
              • Vl-range-strip
              • Vl-maybe-range-strip
            • Stmt-tools
            • Modnamespace
            • Vl-parse-expr-from-str
            • Welltyped
            • Reordering-by-name
            • Flat-warnings
            • Genblob
            • Expr-building
            • Datatype-tools
            • Syscalls
            • Relocate
            • Expr-cleaning
            • Namemangle
            • Caremask
            • Port-tools
            • Lvalues
          • Server
          • Kit
          • Printer
          • Esim-vl
          • Well-formedness
        • Sv
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Stripping-functions

    Vl-namedarglist-strip

    (vl-namedarglist-strip x) maps vl-namedarg-strip across a list.

    Signature
    (vl-namedarglist-strip x) → x-strip
    Arguments
    x — Guard (vl-namedarglist-p x).
    Returns
    x-strip — Type (vl-namedarglist-p x-strip).

    This is an ordinary defprojection.

    Definitions and Theorems

    Function: vl-namedarglist-strip-exec

    (defun vl-namedarglist-strip-exec (x acc)
      (declare (xargs :guard (vl-namedarglist-p x)))
      (declare (xargs :guard t))
      (let ((__function__ 'vl-namedarglist-strip-exec))
        (declare (ignorable __function__))
        (if (consp x)
            (vl-namedarglist-strip-exec
                 (cdr x)
                 (cons (vl-namedarg-strip (car x)) acc))
          acc)))

    Function: vl-namedarglist-strip-nrev

    (defun vl-namedarglist-strip-nrev (x nrev)
      (declare (xargs :stobjs (nrev)))
      (declare (xargs :guard (vl-namedarglist-p x)))
      (declare (xargs :guard t))
      (let ((__function__ 'vl-namedarglist-strip-nrev))
        (declare (ignorable __function__))
        (if (atom x)
            (nrev-fix nrev)
          (let ((nrev (nrev-push (vl-namedarg-strip (car x))
                                 nrev)))
            (vl-namedarglist-strip-nrev (cdr x)
                                        nrev)))))

    Function: vl-namedarglist-strip

    (defun vl-namedarglist-strip (x)
      (declare (xargs :guard (vl-namedarglist-p x)))
      (declare (xargs :guard t))
      (let ((__function__ 'vl-namedarglist-strip))
        (declare (ignorable __function__))
        (mbe :logic
             (if (consp x)
                 (cons (vl-namedarg-strip (car x))
                       (vl-namedarglist-strip (cdr x)))
               nil)
             :exec
             (if (atom x)
                 nil
               (with-local-nrev (vl-namedarglist-strip-nrev x nrev))))))

    Theorem: vl-namedarglist-p-of-vl-namedarglist-strip

    (defthm vl-namedarglist-p-of-vl-namedarglist-strip
      (b* ((x-strip (vl-namedarglist-strip x)))
        (vl-namedarglist-p x-strip))
      :rule-classes :rewrite)

    Theorem: vl-namedarglist-strip-of-vl-namedarglist-fix-x

    (defthm vl-namedarglist-strip-of-vl-namedarglist-fix-x
      (equal (vl-namedarglist-strip (vl-namedarglist-fix x))
             (vl-namedarglist-strip x)))

    Theorem: vl-namedarglist-strip-vl-namedarglist-equiv-congruence-on-x

    (defthm vl-namedarglist-strip-vl-namedarglist-equiv-congruence-on-x
      (implies (vl-namedarglist-equiv x x-equiv)
               (equal (vl-namedarglist-strip x)
                      (vl-namedarglist-strip x-equiv)))
      :rule-classes :congruence)

    Theorem: vl-namedarglist-strip-of-update-nth

    (defthm vl-namedarglist-strip-of-update-nth
     (implies
       (<= (nfix acl2::n) (len acl2::x))
       (equal
            (vl-namedarglist-strip (update-nth acl2::n acl2::v acl2::x))
            (update-nth acl2::n (vl-namedarg-strip acl2::v)
                        (vl-namedarglist-strip acl2::x))))
     :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-of-revappend

    (defthm vl-namedarglist-strip-of-revappend
      (equal (vl-namedarglist-strip (revappend acl2::x acl2::y))
             (revappend (vl-namedarglist-strip acl2::x)
                        (vl-namedarglist-strip acl2::y)))
      :rule-classes ((:rewrite)))

    Theorem: nthcdr-of-vl-namedarglist-strip

    (defthm nthcdr-of-vl-namedarglist-strip
      (equal (nthcdr acl2::n (vl-namedarglist-strip acl2::x))
             (vl-namedarglist-strip (nthcdr acl2::n acl2::x)))
      :rule-classes ((:rewrite)))

    Theorem: nth-of-vl-namedarglist-strip

    (defthm nth-of-vl-namedarglist-strip
      (equal (nth acl2::n (vl-namedarglist-strip acl2::x))
             (and (< (nfix acl2::n) (len acl2::x))
                  (vl-namedarg-strip (nth acl2::n acl2::x))))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-nrev-removal

    (defthm vl-namedarglist-strip-nrev-removal
      (equal (vl-namedarglist-strip-nrev acl2::x nrev)
             (append nrev (vl-namedarglist-strip acl2::x)))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-exec-removal

    (defthm vl-namedarglist-strip-exec-removal
      (equal (vl-namedarglist-strip-exec acl2::x acl2::acc)
             (revappend (vl-namedarglist-strip acl2::x)
                        acl2::acc))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-of-take

    (defthm vl-namedarglist-strip-of-take
      (implies (<= (nfix acl2::n) (len acl2::x))
               (equal (vl-namedarglist-strip (take acl2::n acl2::x))
                      (take acl2::n
                            (vl-namedarglist-strip acl2::x))))
      :rule-classes ((:rewrite)))

    Theorem: set-equiv-congruence-over-vl-namedarglist-strip

    (defthm set-equiv-congruence-over-vl-namedarglist-strip
      (implies (set-equiv acl2::x acl2::y)
               (set-equiv (vl-namedarglist-strip acl2::x)
                          (vl-namedarglist-strip acl2::y)))
      :rule-classes ((:congruence)))

    Theorem: subsetp-of-vl-namedarglist-strip-when-subsetp

    (defthm subsetp-of-vl-namedarglist-strip-when-subsetp
      (implies (subsetp acl2::x acl2::y)
               (subsetp (vl-namedarglist-strip acl2::x)
                        (vl-namedarglist-strip acl2::y)))
      :rule-classes ((:rewrite)))

    Theorem: member-of-vl-namedarg-strip-in-vl-namedarglist-strip

    (defthm member-of-vl-namedarg-strip-in-vl-namedarglist-strip
      (implies (member acl2::k acl2::x)
               (member (vl-namedarg-strip acl2::k)
                       (vl-namedarglist-strip acl2::x)))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-of-rev

    (defthm vl-namedarglist-strip-of-rev
      (equal (vl-namedarglist-strip (rev acl2::x))
             (rev (vl-namedarglist-strip acl2::x)))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-of-list-fix

    (defthm vl-namedarglist-strip-of-list-fix
      (equal (vl-namedarglist-strip (list-fix acl2::x))
             (vl-namedarglist-strip acl2::x))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-of-append

    (defthm vl-namedarglist-strip-of-append
      (equal (vl-namedarglist-strip (append acl2::a acl2::b))
             (append (vl-namedarglist-strip acl2::a)
                     (vl-namedarglist-strip acl2::b)))
      :rule-classes ((:rewrite)))

    Theorem: cdr-of-vl-namedarglist-strip

    (defthm cdr-of-vl-namedarglist-strip
      (equal (cdr (vl-namedarglist-strip acl2::x))
             (vl-namedarglist-strip (cdr acl2::x)))
      :rule-classes ((:rewrite)))

    Theorem: car-of-vl-namedarglist-strip

    (defthm car-of-vl-namedarglist-strip
      (equal (car (vl-namedarglist-strip acl2::x))
             (and (consp acl2::x)
                  (vl-namedarg-strip (car acl2::x))))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-under-iff

    (defthm vl-namedarglist-strip-under-iff
      (iff (vl-namedarglist-strip acl2::x)
           (consp acl2::x))
      :rule-classes ((:rewrite)))

    Theorem: consp-of-vl-namedarglist-strip

    (defthm consp-of-vl-namedarglist-strip
      (equal (consp (vl-namedarglist-strip acl2::x))
             (consp acl2::x))
      :rule-classes ((:rewrite)))

    Theorem: len-of-vl-namedarglist-strip

    (defthm len-of-vl-namedarglist-strip
      (equal (len (vl-namedarglist-strip acl2::x))
             (len acl2::x))
      :rule-classes ((:rewrite)))

    Theorem: true-listp-of-vl-namedarglist-strip

    (defthm true-listp-of-vl-namedarglist-strip
      (true-listp (vl-namedarglist-strip acl2::x))
      :rule-classes :type-prescription)

    Theorem: vl-namedarglist-strip-when-not-consp

    (defthm vl-namedarglist-strip-when-not-consp
      (implies (not (consp acl2::x))
               (equal (vl-namedarglist-strip acl2::x)
                      nil))
      :rule-classes ((:rewrite)))

    Theorem: vl-namedarglist-strip-of-cons

    (defthm vl-namedarglist-strip-of-cons
      (equal (vl-namedarglist-strip (cons acl2::a acl2::b))
             (cons (vl-namedarg-strip acl2::a)
                   (vl-namedarglist-strip acl2::b)))
      :rule-classes ((:rewrite)))