[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs/lisp ChangeLog progmodes/verilog-mode.el
From: |
Dan Nicolaescu |
Subject: |
[Emacs-diffs] emacs/lisp ChangeLog progmodes/verilog-mode.el |
Date: |
Mon, 06 Jul 2009 08:32:54 +0000 |
CVSROOT: /cvsroot/emacs
Module name: emacs
Changes by: Dan Nicolaescu <dann> 09/07/06 08:32:53
Modified files:
lisp : ChangeLog
lisp/progmodes : verilog-mode.el
Log message:
(verilog-error-regexp-emacs-alist): Coded custom
representation of verilog error regular expressions to work with
Emacs-22's new format.
(verilog-error-regexp-xemacs-alist): Coded custom representation
of verilog error regular expressions to work with XEmacs format
(verilog-error-regexp-add-xemacs): Hook routine to install verilog
error recognition into XEmacs.
(verilog-error-regexp-add-emacs): Hook routine to install verilog
error recognition into Emacs-22.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/ChangeLog?cvsroot=emacs&r1=1.15766&r2=1.15767
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/progmodes/verilog-mode.el?cvsroot=emacs&r1=1.28&r2=1.29
Patches:
Index: ChangeLog
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.15766
retrieving revision 1.15767
diff -u -b -r1.15766 -r1.15767
--- ChangeLog 6 Jul 2009 02:17:31 -0000 1.15766
+++ ChangeLog 6 Jul 2009 08:32:48 -0000 1.15767
@@ -1,3 +1,15 @@
+2009-07-07 Michael McNamara <address@hidden>
+
+ * verilog-mode.el (verilog-error-regexp-emacs-alist): Coded custom
+ representation of verilog error regular expressions to work with
+ Emacs-22's new format.
+ (verilog-error-regexp-xemacs-alist): Coded custom representation
+ of verilog error regular expressions to work with XEmacs format
+ (verilog-error-regexp-add-xemacs): Hook routine to install verilog
+ error recognition into XEmacs.
+ (verilog-error-regexp-add-emacs): Hook routine to install verilog
+ error recognition into Emacs-22.
+
2009-07-06 Chong Yidong <address@hidden>
* woman.el: Remove stand-alone closing parentheses.
Index: progmodes/verilog-mode.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/progmodes/verilog-mode.el,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -b -r1.28 -r1.29
--- progmodes/verilog-mode.el 28 Jun 2009 17:52:49 -0000 1.28
+++ progmodes/verilog-mode.el 6 Jul 2009 08:32:53 -0000 1.29
@@ -118,9 +118,9 @@
;;; Code:
;; This variable will always hold the version number of the mode
-(defconst verilog-mode-version "520"
+(defconst verilog-mode-version "525"
"Version of this Verilog mode.")
-(defconst verilog-mode-release-date "2009-06-12-GNU"
+(defconst verilog-mode-release-date "2009-07-02-GNU"
"Release date of this Verilog mode.")
(defconst verilog-mode-release-emacs t
"If non-nil, this version of Verilog mode was released with Emacs itself.")
@@ -627,21 +627,52 @@
(defvar verilog-auto-last-file-locals nil
"Text from file-local-variables during last evaluation.")
-(defvar verilog-error-regexp-add-didit nil)
-(defvar verilog-error-regexp nil)
;;; Compile support
(require 'compile)
-(make-variable-buffer-local 'compilation-error-regexp-systems-list)
-(defvar compilation-error-regexp-alist) ; in case not
-(make-variable-buffer-local 'compilation-error-regexp-alist)
-
+(defvar verilog-error-regexp-added nil)
; List of regexps for Verilog compilers, like verilint. See
compilation-error-regexp-alist
; for the formatting.
-(defvar verilog-error-regexp-alist
+; Here is the version for Emacs 22:
+(defvar verilog-error-regexp-emacs-alist
+ '(
+ (verilog-xl-1
+ "\\(Error\\|Warning\\)!.*\n?.*\"\\([^\"]+\\)\", \\([0-9]+\\)" 2 3)
+ (verilog-xl-2
+ "([WE][0-9A-Z]+)[ \t]+\\([^ \t\n,]+\\)[, \t]+\\(line[
\t]+\\)?\\([0-9]+\\):.*$" 1 3)
+ (verilog-IES
+ ".*\\*[WE],[0-9A-Z]+ (\\([^ \t,]+\\),\\([0-9]+\\)" 1 2)
+ (verilog-surefire-1
+ "[^\n]*\\[\\([^:]+\\):\\([0-9]+\\)\\]" 1 2)
+ (verilog-surefire-2
+ "\\(WARNING\\|ERROR\\|INFO\\)[^:]*: \\([^,]+\\),\\s-+\\(line
\\)?\\([0-9]+\\):" 2 4 )
+ (verilog-verbose
+ "\
+\\([a-zA-Z]?:?[^:( \t\n]+\\)[:(][ \t]*\\([0-9]+\\)\\([) \t]\\|\
+:\\([^0-9\n]\\|\\([0-9]+:\\)\\)\\)" 1 2 5)
+ (verilog-xsim
+ "\\(Error\\|Warning\\).*in file (\\([^ \t]+\\) at line *\\([0-9]+\\))" 2
3)
+ (verilog-vcs-1
+ "\\(Error\\|Warning\\):[^(]*(\\([^ \t]+\\) line *\\([0-9]+\\))" 2 3)
+ (verilog-vcs-2
+ "Warning:.*(port.*(\\([^ \t]+\\) line \\([0-9]+\\))" 1 2)
+ (verilog-vcs-3
+ "\\(Error\\|Warning\\):[\n.]*\\([^ \t]+\\) *\\([0-9]+\\):" 2 3)
+ (verilog-vcs-4
+ "syntax error:.*\n\\([^ \t]+\\) *\\([0-9]+\\):" 1 2)
+ (verilog-verilator
+ "%?\\(Error\\|Warning\\)\\(-[^:]+\\|\\):[\n ]*\\([^
\t:]+\\):\\([0-9]+\\):" 3 4)
+ (verilog-leda
+ "In file \\([^ \t]+\\)[ \t]+line[ \t]+\\([0-9]+\\):
+.*
+.*
+.*
+\\(Warning\\|Error\\|Failure\\)" 1 2)
+ ))
+;; And the version for XEmacs:
+(defvar verilog-error-regexp-xemacs-alist
'(verilog
-; SureLint
("[^\n]*\\[\\([^:]+\\):\\([0-9]+\\)\\]" 1 2)
- ("\\(WARNING\\|ERROR\\|INFO\\)[^:]*: \\([^,]+\\), \\(line
\\|\\)\\([0-9]+\\):" 2 4 )
+ ("\\(WARNING\\|ERROR\\|INFO\\)[^:]*: \\([^,]+\\),\\s-+\\(line
\\)?\\([0-9]+\\):" 2 4 )
("\
\\([a-zA-Z]?:?[^:( \t\n]+\\)[:(][ \t]*\\([0-9]+\\)\\([) \t]\\|\
:\\([^0-9\n]\\|\\([0-9]+:\\)\\)\\)" 1 2 5)
@@ -655,7 +686,6 @@
("syntax error:.*\n\\([^ \t]+\\) *\\([0-9]+\\):" 1 2)
; Verilator
("%?\\(Error\\|Warning\\)\\(-[^:]+\\|\\):[\n ]*\\([^
\t:]+\\):\\([0-9]+\\):" 3 4)
- ("%?\\(Error\\|Warning\\)\\(-[^:]+\\|\\):[\n ]*\\([^
\t:]+\\):\\([0-9]+\\):" 3 4)
; verilog-xl
("\\(Error\\|Warning\\)!.*\n?.*\"\\([^\"]+\\)\", \\([0-9]+\\)" 2 3)
("([WE][0-9A-Z]+)[ \t]+\\([^ \t\n,]+\\)[, \t]+\\([0-9]+\\):.*$" 1 2)
; vxl
@@ -664,7 +694,8 @@
(".*\\*[WE],[0-9A-Z]+ (\\([^ \t,]+\\),\\([0-9]+\\)|" 1 2)
; Leda
("In file \\([^ \t]+\\)[ \t]+line[
\t]+\\([0-9]+\\):\n[^\n]*\n[^\n]*\n\\[\\(Warning\\|Error\\|Failure\\)\\][^\n]*"
1 2)
- ))
+ )
+ )
(defvar verilog-error-font-lock-keywords
'(
@@ -1424,46 +1455,49 @@
t t compile-command))))
;; Following code only gets called from compilation-mode-hook on XEmacs to add
error handling.
-;; There is no way to add this on the fly to Emacs; instead we must update
compile.el
-(if (featurep 'xemacs)
- (defun verilog-error-regexp-add-xemacs ()
+(defun verilog-error-regexp-add-xemacs ()
"Teach XEmacs about verilog errors.
Called by `compilation-mode-hook'. This allows \\[next-error] to
find the errors."
(interactive)
- (if 't ; (not verilog-error-regexp-add-didit)
- (progn
- (if (or (equal compilation-error-regexp-systems-list 'all)
- (not (member 'verilog
compilation-error-regexp-systems-list)))
- (setq compilation-error-regexp-systems-list
- (if (listp compilation-error-regexp-systems-list)
- (nconc compilation-error-regexp-systems-list 'verilog)
- 'verilog)))
+ (if (boundp 'compilation-error-regexp-systems-alist)
+ (if (and
+ (not (equal compilation-error-regexp-systems-list 'all))
+ (not (member compilation-error-regexp-systems-list 'verilog)))
+ (push 'verilog compilation-error-regexp-systems-list)))
+ (if (boundp 'compilation-error-regexp-alist-alist)
(if (not (assoc 'verilog compilation-error-regexp-alist-alist))
(setcdr compilation-error-regexp-alist-alist
- (cons verilog-error-regexp-alist
- (cdr compilation-error-regexp-alist-alist))))
+ (cons verilog-error-regexp-xemacs-alist
+ (cdr compilation-error-regexp-alist-alist)))))
+ (if (boundp 'compilation-font-lock-keywords)
+ (progn
+ (make-variable-buffer-local 'compilation-font-lock-keywords)
+ (setq compilation-font-lock-keywords verilog-error-font-lock-keywords)
+ (font-lock-set-defaults)))
;; Need to re-run compilation-error-regexp builder
- (compilation-build-compilation-error-regexp-alist))))
+ (if (fboundp 'compilation-build-compilation-error-regexp-alist)
+ (compilation-build-compilation-error-regexp-alist))
)
+
+;; Following code only gets called from compilation-mode-hook on Emacs to add
error handling.
(defun verilog-error-regexp-add-emacs ()
"Tell Emacs compile that we are Verilog.
Called by `compilation-mode-hook'. This allows \\[next-error] to
find the errors."
(interactive)
-;; Turned off because there seems no way to do this outside of compile.el
-;;
-;; (if (or (equal compilation-error-regexp-alist 'all)
-;; (not (member 'verilog compilation-error-regexp-alist)))
-;; (setq compilation-error-regexp-alist
-;; (if (listp compilation-error-regexp-alist)
-;; (append '(verilog) compilation-error-regexp-alist)
-;; '(verilog) )))
+ (if (boundp 'compilation-error-regexp-alist-alist)
+ (progn
+ (if (not (assoc 'verilog-xl-1 compilation-error-regexp-alist-alist))
+ (mapcar
+ (lambda (item)
+ (push (car item) compilation-error-regexp-alist)
+ (push item compilation-error-regexp-alist-alist)
)
+ verilog-error-regexp-emacs-alist)))))
-(if (featurep 'xemacs)
- (add-hook 'compilation-mode-hook 'verilog-error-regexp-add-xemacs)
- (add-hook 'compilation-mode-hook 'verilog-error-regexp-add-emacs))
+(if (featurep 'xemacs) (add-hook 'compilation-mode-hook
'verilog-error-regexp-add-xemacs))
+(if (featurep 'emacs) (add-hook 'compilation-mode-hook
'verilog-error-regexp-add-emacs))
(defconst verilog-directive-re
;; "`case" "`default" "`define" "`define" "`else" "`endfor" "`endif"
- [Emacs-diffs] emacs/lisp ChangeLog progmodes/verilog-mode.el,
Dan Nicolaescu <=