(vl-parse-named-port-connection &key (tokstream 'tokstream) (config 'config)) → (mv errmsg? value new-tokstream)
Function:
(defun vl-parse-named-port-connection-fn (tokstream config) (declare (xargs :stobjs (tokstream))) (declare (xargs :guard (vl-loadconfig-p config))) (declare (ignorable config)) (let ((__function__ 'vl-parse-named-port-connection)) (declare (ignorable __function__)) (seq tokstream (atts := (vl-parse-0+-attribute-instances)) (:= (vl-match-token :vl-dot)) (id := (vl-match-token :vl-idtoken)) (when (vl-is-token? :vl-lparen) (:= (vl-match)) (unless (vl-is-token? :vl-rparen) (expr := (vl-parse-expression))) (:= (vl-match-token :vl-rparen)) (return (make-vl-namedarg :name (vl-idtoken->name id) :expr expr :nameonly-p nil :atts atts))) (when (eq (vl-loadconfig->edition config) :verilog-2005) (return-raw (vl-parse-error "Expected argument to named port connect."))) (return (make-vl-namedarg :name (vl-idtoken->name id) :expr (vl-idexpr (vl-idtoken->name id)) :nameonly-p t :atts atts)))))
Theorem:
(defthm vl-parse-named-port-connection-fails-gracefully (implies (mv-nth 0 (vl-parse-named-port-connection)) (not (mv-nth 1 (vl-parse-named-port-connection)))))
Theorem:
(defthm vl-warning-p-of-vl-parse-named-port-connection (iff (vl-warning-p (mv-nth 0 (vl-parse-named-port-connection))) (mv-nth 0 (vl-parse-named-port-connection))))
Theorem:
(defthm vl-parse-named-port-connection-result (implies (and t) (equal (vl-namedarg-p (mv-nth 1 (vl-parse-named-port-connection))) (not (mv-nth 0 (vl-parse-named-port-connection))))))
Theorem:
(defthm vl-parse-named-port-connection-count-strong (and (<= (vl-tokstream-measure :tokstream (mv-nth 2 (vl-parse-named-port-connection))) (vl-tokstream-measure)) (implies (not (mv-nth 0 (vl-parse-named-port-connection))) (< (vl-tokstream-measure :tokstream (mv-nth 2 (vl-parse-named-port-connection))) (vl-tokstream-measure)))) :rule-classes ((:rewrite) (:linear)))