• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • 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
            • Parse-expressions
            • Parse-udps
            • Vl-genelements
            • Parse-paramdecls
            • Parse-blockitems
            • Parse-utils
            • Parse-insts
            • Parse-datatype
            • Parse-functions
            • Parse-datatypes
            • Parse-strengths
            • Vl-parse-genvar-declaration
            • Vl-parse
            • Parse-ports
              • Parse-port-types
              • Sv-ansi-portdecls
              • Creating-portdecls/vardecls
              • Sv-non-ansi-portdecls
              • Verilog-2005-ports
              • Sv-ansi-port-interpretation
              • Verilog-2005-portdecls
                • Vl-parse-basic-port-declaration-tail
                • Vl-parse-port-declaration-noatts-2005
                • Vl-parse-port-declaration-atts-2005
                • Vl-parse-1+-port-declarations-separated-by-commas-2005
                • Vl-parse-1+-identifiers-separated-by-commas
                • Vl-parse-port-declaration-noatts
                • Vl-parse-module-port-list-top-2005
                • Vl-parse-output-reg-port-tail
              • Seq
              • Parse-packages
            • 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-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
    • Verilog-2005-portdecls

    Vl-parse-output-reg-port-tail

    We've just matched 'output reg'. Now match ['signed'] [range] list_of_variable_port_identifiers.

    Signature
    (vl-parse-output-reg-port-tail atts &key (tokstream 'tokstream) 
                                   (config 'config)) 
     
      → 
    (mv errmsg? value new-tokstream)
    Arguments
    config — Guard (vl-loadconfig-p config).

    Definitions and Theorems

    Function: vl-parse-output-reg-port-tail-fn

    (defun vl-parse-output-reg-port-tail-fn (atts tokstream config)
     (declare (xargs :stobjs (tokstream)))
     (declare (xargs :guard (vl-loadconfig-p config)))
     (declare (ignorable config))
     (declare (xargs :guard (vl-atts-p atts)))
     (let ((__function__ 'vl-parse-output-reg-port-tail))
      (declare (ignorable __function__))
      (seq
       tokstream
       (when (vl-is-token? :vl-kwd-signed)
             (signed := (vl-match)))
       (when (vl-is-token? :vl-lbrack)
             (range := (vl-parse-range)))
       (ids := (vl-parse-1+-identifiers-separated-by-commas))
       (return
        (vl-make-ports-and-maybe-nets
           (vl-parsed-port-identifier-list-from-idtokenlist ids)
           :dir :vl-output
           :atts atts
           :complete-p t
           :type (make-vl-coretype :name :vl-reg
                                   :signedp (if signed t nil)
                                   :pdims (and range (list range))))))))

    Theorem: vl-parse-output-reg-port-tail-fails-gracefully

    (defthm vl-parse-output-reg-port-tail-fails-gracefully
      (implies (mv-nth 0 (vl-parse-output-reg-port-tail atts))
               (not (mv-nth 1
                            (vl-parse-output-reg-port-tail atts)))))

    Theorem: vl-warning-p-of-vl-parse-output-reg-port-tail

    (defthm vl-warning-p-of-vl-parse-output-reg-port-tail
     (iff (vl-warning-p (mv-nth 0 (vl-parse-output-reg-port-tail atts)))
          (mv-nth 0
                  (vl-parse-output-reg-port-tail atts))))

    Theorem: vl-parse-output-reg-port-tail-result

    (defthm vl-parse-output-reg-port-tail-result
     (implies
          (and (force (vl-atts-p atts)))
          (equal (consp (mv-nth 1 (vl-parse-output-reg-port-tail atts)))
                 (not (mv-nth 0
                              (vl-parse-output-reg-port-tail atts))))))

    Theorem: vl-parse-output-reg-port-tail-count-strong

    (defthm vl-parse-output-reg-port-tail-count-strong
     (and
      (<=
        (vl-tokstream-measure
             :tokstream (mv-nth 2 (vl-parse-output-reg-port-tail atts)))
        (vl-tokstream-measure))
      (implies
       (not (mv-nth 0 (vl-parse-output-reg-port-tail atts)))
       (<
        (vl-tokstream-measure
             :tokstream (mv-nth 2 (vl-parse-output-reg-port-tail atts)))
        (vl-tokstream-measure))))
     :rule-classes ((:rewrite) (:linear)))

    Theorem: true-listp-of-vl-parse-output-reg-port-tail-1

    (defthm true-listp-of-vl-parse-output-reg-port-tail-1
      (true-listp (car (mv-nth 1
                               (vl-parse-output-reg-port-tail atts))))
      :rule-classes :type-prescription)

    Theorem: true-listp-of-vl-parse-output-reg-port-tail-2

    (defthm true-listp-of-vl-parse-output-reg-port-tail-2
      (true-listp (cdr (mv-nth 1
                               (vl-parse-output-reg-port-tail atts))))
      :rule-classes :type-prescription)

    Theorem: vl-parse-output-reg-port-tail-basics

    (defthm vl-parse-output-reg-port-tail-basics
      (and (vl-portdecllist-p
                (car (mv-nth 1
                             (vl-parse-output-reg-port-tail atts))))
           (vl-vardecllist-p
                (cdr (mv-nth 1
                             (vl-parse-output-reg-port-tail atts))))))