Function: vhdl-update-sensitivity-list-process

vhdl-update-sensitivity-list-process is an interactive and byte-compiled function defined in vhdl-mode.el.gz.

Signature

(vhdl-update-sensitivity-list-process)

Documentation

Update sensitivity list of current process.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/vhdl-mode.el.gz
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Code updating/fixing
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Sensitivity list update

;; Strategy:
;; - no sensitivity list is generated for processes with wait statements
;; - otherwise, do the following:
;;   1. scan for all local signals (ports, signals declared in arch./blocks)
;;   2. scan for all signals already in the sensitivity list (in order to catch
;;      manually entered global signals)
;;   3. signals from 1. and 2. form the list of visible signals
;;   4. search for if/elsif conditions containing an event (sequential code)
;;   5. scan for strings that are within syntactical regions where signals are
;;      read but not within sequential code, and that correspond to visible
;;      signals
;;   6. replace sensitivity list by list of signals from 5.

(defun vhdl-update-sensitivity-list-process ()
  "Update sensitivity list of current process."
  (interactive)
  (save-excursion
    (vhdl-prepare-search-2
     (end-of-line)
     ;; look whether in process
     (if (not (and (re-search-backward "^\\s-*\\(\\w+[ \t\n\r\f]*:[ \t\n\r\f]*\\)?\\(process\\|end\\s-+process\\)\\>" nil t)
		   (equal (upcase (match-string 2)) "PROCESS")
		   (save-excursion (re-search-forward "^\\s-*end\\s-+process\\>" nil t))))
	 (error "ERROR:  Not within a process")
       (message "Updating sensitivity list...")
       (vhdl-update-sensitivity-list)
       (message "Updating sensitivity list...done")))))