• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
      • Gl
      • Esim
      • Vl2014
        • Warnings
        • Primitives
        • Use-set
        • Syntax
        • Getting-started
        • Utilities
        • Loader
          • Preprocessor
          • Vl-loadconfig
          • Lexer
          • Vl-loadstate
          • Parser
          • Vl-load-merge-descriptions
          • Scope-of-defines
          • Vl-load-file
          • Vl-flush-out-descriptions
          • Vl-description
          • Vl-loadresult
          • Vl-read-file
          • Vl-find-basename/extension
          • Vl-find-file
          • Vl-read-files
          • Extended-characters
            • Vl-echar-p
            • Vl-location
              • Vl-location-p
                • Vl-location-fix
                • Vl-string-between-locs
                • Vl-location-between-p
                • Vl-string-findloc
                • Vl-location-equiv
                • Make-vl-location
                • Vl-location-string
                • Vl-location->filename
                • Vl-location->line
                • Change-vl-location
                • Vl-location->col
                • *vl-fakeloc*
              • Vl-echarlist->chars
              • Vl-echarlist-from-chars
              • Vl-echarlist-from-str
              • Vl-echarlist-unsigned-value
              • Vl-change-echarlist-locations
              • Vl-echar-digit-value
              • Vl-echarlist->string
            • Vl-load
            • Vl-load-main
            • Vl-load-description
            • Vl-descriptions-left-to-load
            • Inject-warnings
            • Vl-load-descriptions
            • Vl-load-files
            • Vl-load-summary
            • Vl-collect-modules-from-descriptions
            • Vl-descriptionlist
          • Transforms
          • Lint
          • Mlib
          • Server
          • Kit
          • Printer
          • Esim-vl
          • Well-formedness
        • Sv
        • Fgl
        • Vwsim
        • Vl
        • X86isa
        • Svl
        • Rtl
      • Software-verification
      • Math
      • Testing-utilities
    • Vl-location

    Vl-location-p

    Recognizer for vl-location structures.

    Signature
    (vl-location-p x) → *

    Definitions and Theorems

    Function: vl-location-p

    (defun vl-location-p (x)
      (declare (xargs :guard t))
      (let ((__function__ 'vl-location-p))
        (declare (ignorable __function__))
        (and (consp x)
             (eq (car x) :vl-location)
             (std::prod-consp (cdr x))
             (std::prod-consp (std::prod-cdr (cdr x)))
             (b* ((filename (std::prod-car (cdr x)))
                  (line (std::prod-car (std::prod-cdr (cdr x))))
                  (col (std::prod-cdr (std::prod-cdr (cdr x)))))
               (and (stringp filename)
                    (posp line)
                    (natp col))))))

    Theorem: consp-when-vl-location-p

    (defthm consp-when-vl-location-p
      (implies (vl-location-p x) (consp x))
      :rule-classes :compound-recognizer)