PATCH packages
The VHDL mode home page has moved, so this seems like a good time for an
update.
xemacs-packages/vhdl/ChangeLog addition:
2006-08-09 Jerry James <james(a)xemacs.org>
* ChangeLog.upstream: Update from 3.33.12.
* vhdl-mode.el: Sync with 3.33.12.
* vhdl-mode.texi: Fix a minor typo.
* Makefile (AUTHOR_VERSION): Change to 3.33.12.
packages source patch:
Diff command: cvs -q diff -uN
Files affected: xemacs-packages/vhdl/Makefile
===================================================================
RCS xemacs-packages/vhdl/vhdl-mode.texi
===================================================================
RCS xemacs-packages/vhdl/vhdl-mode.el
===================================================================
RCS xemacs-packages/vhdl/ChangeLog.upstream
===================================================================
RCS
Index: xemacs-packages/vhdl/ChangeLog.upstream
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/vhdl/ChangeLog.upstream,v
retrieving revision 1.1
diff -d -u -r1.1 ChangeLog.upstream
--- xemacs-packages/vhdl/ChangeLog.upstream 2006/04/18 16:26:34 1.1
+++ xemacs-packages/vhdl/ChangeLog.upstream 2006/08/09 16:03:12
@@ -1,3 +1,46 @@
+2006-05-23 Reto Zimmermann <reto(a)gnu.org>
+
+ * vhdl-mode.el: Version 3.33.12 released.
+ (vhdl-in-quote-p): Handle single quoted characters correctly.
+ (vhdl-begin-*-re): Fix indentation for "if/case ... use".
+ (vhdl-fixup-whitespace-region): Add "??" operator.
+ (vhdl-corresponding-end): Fix indentation for "if/case ... use".
+
+2006-05-16 Reto Zimmermann <reto(a)gnu.org>
+
+ * vhdl-mode.el
+ (vhdl-align-region-2): Not align at end of line.
+ (vhdl-in-literal): Also check character quotes (single quote).
+ (vhdl-align-region-2): Fix in-literal checking.
+ (vhdl-fixup-whitespace-region): Add ?= ?/= ?> ?>= ?< ?<= operators.
+
+2006-05-15 Reto Zimmermann <reto(a)gnu.org>
+
+ * vhdl-mode.el: Version 3.33.11 released.
+ (vhdl-fixup-whitespace-region): Correctly handle single '-'.
+ (vhdl-align-region-2, vhdl-fixup-whitespace-region): Handle at boi.
+ (vhdl-get-syntactic-context): Fix argument list indentation.
+
+2006-05-11 Reto Zimmermann <reto(a)gnu.org>
+
+ * vhdl-mode.el: Version 3.33.10 released.
+ (vhdl-compile): Use relative path for compiled files by default.
+ (vhdl-compile-absolute-path): Use absolute path for compiled files.
+ (vhdl-begin-p): Fix indentation for "-- when".
+
+2006-04-12 Reto Zimmermann <reto(a)gnu.org>
+
+ * vhdl-mode.el: Version 3.33.8 released.
+ (vhdl-compiler-alist): Add "Aldec" simulator.
+ (vhdl-get-visible-signals): Allow "port ..." in middle of line.
+ (vhdl-fixup-whitespace-region): Fix whitespace removal before comma.
+ (top): Update for VHDL'02 standard (add 'protected' keyword).
+
+2006-01-13 Reto Zimmermann <reto(a)gnu.org>
+
+ * vhdl-mode.el:
+ (vhdl-mode): Remove 'fill-prefix' definition for XEmacs (breaks else).
+
2005-12-09 Reto Zimmermann <reto(a)gnu.org>
* vhdl-mode.el: Version 3.33.7 released.
Index: xemacs-packages/vhdl/vhdl-mode.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/vhdl/vhdl-mode.el,v
retrieving revision 1.9
diff -d -u -r1.9 vhdl-mode.el
--- xemacs-packages/vhdl/vhdl-mode.el 2006/04/18 16:26:34 1.9
+++ xemacs-packages/vhdl/vhdl-mode.el 2006/08/09 16:03:13
@@ -1,18 +1,18 @@
;;; vhdl-mode.el --- major mode for editing VHDL code
-;; Copyright (C) 1992-2005 Free Software Foundation, Inc.
+;; Copyright (C) 1992-2006 Free Software Foundation, Inc.
;; Authors: Reto Zimmermann <reto(a)gnu.org>
;; Rodney J. Whitby <software.vhdl-mode(a)rwhitby.net>
;; Maintainer: Reto Zimmermann <reto(a)gnu.org>
-;; RCS: $Id: vhdl-mode.el,v 1.9 2006/04/18 16:26:34 james Exp $
+;; RCS: $Id: vhdl-mode.el,v 33.24 2006/05/23 13:07:18 reto Exp reto $
;; Keywords: languages vhdl
-;; WWW:
http://opensource.ethz.ch/emacs/vhdl-mode.html
+;; WWW:
http://www.iis.ee.ethz.ch/~zimmi/emacs/vhdl-mode.html
-(defconst vhdl-version "3.33.8"
+(defconst vhdl-version "3.33.12"
"VHDL Mode version number.")
-(defconst vhdl-time-stamp "2005-12-09"
+(defconst vhdl-time-stamp "2006-05-23"
"VHDL Mode time stamp for last update.")
;; This file is part of GNU Emacs.
@@ -57,7 +57,7 @@
;; - Block commenting
;; - Code fixing/alignment/beautification
;; - Postscript printing
-;; - VHDL'87/'93 and VHDL-AMS supported
+;; - VHDL'87/'93/'02 and VHDL-AMS supported
;; - Comprehensive menu
;; - Fully customizable
;; - Works under GNU Emacs (recommended) and XEmacs
@@ -221,6 +221,12 @@
(defcustom vhdl-compiler-alist
'(
+ ;; Aldec
+ ;; COMP96 ERROR COMP96_0078: "Unknown identifier "Addr_Bits"."
"<filename>" 40 30
+ ("Aldec" "vcom" "-93 -work \\1" "make"
"-f \\1"
+ nil "vlib \\1; vmap \\2 \\1" "./" "work/"
"Makefile" "aldec"
+ (".+?[ \t]+\\(?:ERROR\\)[^:]+:.+?\\(?:.+\"\\(.+?\\)\"[
\t]+\\([0-9]+\\)\\)" 1 2 0) ("" 0)
+ nil)
;; Cadence Leapfrog: cv -file test.vhd
;; duluth: *E,430 (test.vhd,13): identifier (POSITIV) is not declared
("Cadence Leapfrog" "cv" "-work \\1 -file"
"make" "-f \\1"
@@ -668,7 +674,7 @@
"*VHDL standards used.
Basic standard:
VHDL'87 : IEEE Std 1076-1987
- VHDL'93 : IEEE Std 1076-1993
+ VHDL'93/02 : IEEE Std 1076-1993/2002
Additional standards:
VHDL-AMS : IEEE Std 1076.1 (analog-mixed-signal)
Math packages: IEEE Std 1076.2 (`math_real', `math_complex')
@@ -677,7 +683,7 @@
\"Activate Options\"."
:type '(list (choice :tag "Basic standard"
(const :tag "VHDL'87" 87)
- (const :tag "VHDL'93" 93))
+ (const :tag "VHDL'93/02" 93))
(set :tag "Additional standards" :indent 2
(const :tag "VHDL-AMS" ams)
(const :tag "Math packages" math)))
@@ -1792,7 +1798,7 @@
(defcustom vhdl-intelligent-tab t
"*Non-nil means `TAB' does indentation, word completion and tab insertion.
-That is, if preceeding character is part of a word then complete word,
+That is, if preceding character is part of a word then complete word,
else if not at beginning of line then insert tab,
else if last command was a `TAB' or `RET' then dedent one step,
else indent current line (i.e. `TAB' is bound to `vhdl-electric-tab').
@@ -2898,7 +2904,7 @@
(define-abbrev-table 'vhdl-mode-abbrev-table
(append
(when (memq 'vhdl vhdl-electric-keywords)
- ;; VHDL'93 keywords
+ ;; VHDL'02 keywords
'(
("--" "" vhdl-template-display-comment-hook 0)
("abs" "" vhdl-template-default-hook 0)
@@ -2975,6 +2981,7 @@
("postponed" "" vhdl-template-default-hook 0)
("procedure" "" vhdl-template-procedure-hook 0)
("process" "" vhdl-template-process-hook 0)
+ ("protected" "" vhdl-template-default-hook 0)
("pure" "" vhdl-template-default-hook 0)
("range" "" vhdl-template-default-hook 0)
("record" "" vhdl-template-default-hook 0)
@@ -3569,7 +3576,7 @@
(list '87 (cadr vhdl-standard)))
(vhdl-activate-customizations))
:style radio :selected (eq '87 (car vhdl-standard))]
- ["VHDL'93"
+ ["VHDL'93/02"
(progn (customize-set-variable 'vhdl-standard
(list '93 (cadr vhdl-standard)))
(vhdl-activate-customizations))
@@ -4522,7 +4529,7 @@
VHDL STANDARDS:
The VHDL standards to be used are specified in option `vhdl-standard'.
- Available standards are: VHDL'87/'93, VHDL-AMS, and Math Packages.
+ Available standards are: VHDL'87/'93(02), VHDL-AMS, and Math Packages.
KEYWORD CASE:
@@ -4671,14 +4678,13 @@
to above mailing lists by sending an email to <reto(a)gnu.org>.
VHDL Mode is officially distributed at
-http://opensource.ethz.ch/emacs/vhdl-mode.html
+http://www.iis.ee.ethz.ch/~zimmi/emacs/vhdl-mode.html
where the latest version can be found.
Known problems:
---------------
-- Indentation bug in simultaneous if- and case-statements (VHDL-AMS).
- XEmacs: Incorrect start-up when automatically opening speedbar.
- XEmacs: Indentation in XEmacs 21.4 (and higher).
@@ -4814,7 +4820,7 @@
;;; Keywords and standardized words
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(defconst vhdl-93-keywords
+(defconst vhdl-02-keywords
'(
"abs" "access" "after" "alias"
"all" "and" "architecture" "array"
"assert" "attribute"
@@ -4829,7 +4835,7 @@
"map" "mod"
"nand" "new" "next" "nor" "not"
"null"
"of" "on" "open" "or" "others"
"out"
- "package" "port" "postponed" "procedure"
"process" "pure"
+ "package" "port" "postponed" "procedure"
"process" "protected" "pure"
"range" "record" "register" "reject"
"rem" "report" "return"
"rol" "ror"
"select" "severity" "shared" "signal"
"sla" "sll" "sra" "srl" "subtype"
@@ -4839,7 +4845,7 @@
"wait" "when" "while" "with"
"xnor" "xor"
)
- "List of VHDL'93 keywords.")
+ "List of VHDL'02 keywords.")
(defconst vhdl-ams-keywords
'(
@@ -4872,7 +4878,7 @@
)
"List of Verilog keywords as candidate for additional reserved words.")
-(defconst vhdl-93-types
+(defconst vhdl-02-types
'(
"boolean" "bit" "bit_vector" "character"
"severity_level" "integer"
"real" "time" "natural" "positive"
"string" "line" "text" "side"
@@ -4880,7 +4886,7 @@
"std_logic" "std_logic_vector"
"std_ulogic" "std_ulogic_vector"
)
- "List of VHDL'93 standardized types.")
+ "List of VHDL'02 standardized types.")
(defconst vhdl-ams-types
'(
@@ -4898,7 +4904,7 @@
)
"List of Math Packages standardized types.")
-(defconst vhdl-93-attributes
+(defconst vhdl-02-attributes
'(
"base" "left" "right" "high" "low"
"pos" "val" "succ"
"pred" "leftof" "rightof" "range"
"reverse_range"
@@ -4908,7 +4914,7 @@
"simple_name" "instance_name" "path_name"
"foreign"
)
- "List of VHDL'93 standardized attributes.")
+ "List of VHDL'02 standardized attributes.")
(defconst vhdl-ams-attributes
'(
@@ -4919,7 +4925,7 @@
)
"List of VHDL-AMS standardized attributes.")
-(defconst vhdl-93-enum-values
+(defconst vhdl-02-enum-values
'(
"true" "false"
"note" "warning" "error" "failure"
@@ -4928,7 +4934,7 @@
"fs" "ps" "ns" "us" "ms"
"sec" "min" "hr"
"right" "left"
)
- "List of VHDL'93 standardized enumeration values.")
+ "List of VHDL'02 standardized enumeration values.")
(defconst vhdl-ams-enum-values
'(
@@ -4950,7 +4956,7 @@
)
"List of Math Packages standardized constants.")
-(defconst vhdl-93-functions
+(defconst vhdl-02-functions
'(
"now" "resolved" "rising_edge"
"falling_edge"
"read" "readline" "write" "writeline"
"endfile"
@@ -4963,7 +4969,7 @@
"shl" "shr" "ext" "sxt"
"deallocate"
)
- "List of VHDL'93 standardized functions.")
+ "List of VHDL'02 standardized functions.")
(defconst vhdl-ams-functions
'(
@@ -4981,7 +4987,7 @@
)
"List of Math Packages standardized functions.")
-(defconst vhdl-93-packages
+(defconst vhdl-02-packages
'(
"std_logic_1164" "numeric_std" "numeric_bit"
"standard" "textio"
@@ -4989,7 +4995,7 @@
"std_logic_misc" "std_logic_textio"
"ieee" "std" "work"
)
- "List of VHDL'93 standardized packages and libraries.")
+ "List of VHDL'02 standardized packages and libraries.")
(defconst vhdl-ams-packages
'(
@@ -5055,26 +5061,26 @@
(defun vhdl-words-init ()
"Initialize reserved words."
(setq vhdl-keywords
- (append vhdl-93-keywords
+ (append vhdl-02-keywords
(when (vhdl-standard-p 'ams) vhdl-ams-keywords)))
(setq vhdl-types
- (append vhdl-93-types
+ (append vhdl-02-types
(when (vhdl-standard-p 'ams) vhdl-ams-types)
(when (vhdl-standard-p 'math) vhdl-math-types)))
(setq vhdl-attributes
- (append vhdl-93-attributes
+ (append vhdl-02-attributes
(when (vhdl-standard-p 'ams) vhdl-ams-attributes)))
(setq vhdl-enum-values
- (append vhdl-93-enum-values
+ (append vhdl-02-enum-values
(when (vhdl-standard-p 'ams) vhdl-ams-enum-values)))
(setq vhdl-constants
(append (when (vhdl-standard-p 'math) vhdl-math-constants)))
(setq vhdl-functions
- (append vhdl-93-functions
+ (append vhdl-02-functions
(when (vhdl-standard-p 'ams) vhdl-ams-functions)
(when (vhdl-standard-p 'math) vhdl-math-functions)))
(setq vhdl-packages
- (append vhdl-93-packages
+ (append vhdl-02-packages
(when (vhdl-standard-p 'ams) vhdl-ams-packages)
(when (vhdl-standard-p 'math) vhdl-math-packages)))
(setq vhdl-reserved-words
@@ -5369,6 +5375,17 @@
"Check if point is in a string."
(eq (vhdl-in-literal) 'string))
+(defun vhdl-in-quote-p ()
+ "Check if point is in a quote ('x')."
+ (or (and (> (point) (point-min))
+ (< (1+ (point)) (point-max))
+ (= (char-before (point)) ?\')
+ (= (char-after (1+ (point))) ?\'))
+ (and (> (1- (point)) (point-min))
+ (< (point) (point-max))
+ (= (char-before (1- (point))) ?\')
+ (= (char-after (point)) ?\'))))
+
(defun vhdl-in-literal ()
"Determine if point is in a VHDL literal."
(save-excursion
@@ -5604,12 +5621,12 @@
"is"))))
(defconst vhdl-begin-fwd-re
-
"\\b\\(is\\|begin\\|block\\|component\\|generate\\|then\\|else\\|loop\\|process\\|procedural\\|units\\|record\\|for\\)\\b\\([^_]\\|\\'\\)"
+
"\\b\\(is\\|begin\\|block\\|component\\|generate\\|then\\|else\\|loop\\|process\\|procedural\\(\\s-+body\\)?\\|units\\|use\\|record\\|for\\)\\b\\([^_]\\|\\'\\)"
"A regular expression for searching forward that matches all known
\"begin\" keywords.")
(defconst vhdl-begin-bwd-re
-
"\\b\\(is\\|begin\\|block\\|component\\|generate\\|then\\|else\\|loop\\|process\\|procedural\\|units\\|record\\|for\\)\\b[^_]"
+
"\\b\\(is\\|begin\\|block\\|component\\|generate\\|then\\|else\\|loop\\|process\\|procedural\\(\\s-+body\\)?\\|units\\|use\\|record\\|for\\)\\b[^_]"
"A regular expression for searching backward that matches all known
\"begin\" keywords.")
@@ -5642,15 +5659,15 @@
(and (/= (following-char) ?\;)
(not (looking-at "is\\|begin\\|process\\|procedural\\|block")))))
t)
- ;; "begin", "then":
- ((looking-at "be\\|t")
+ ;; "begin", "then", "use":
+ ((looking-at "be\\|t\\|use")
t)
;; "else":
((and (looking-at "e")
;; make sure that the "else" isn't inside a
;; conditional signal assignment.
(save-excursion
- (re-search-backward ";\\|\\bwhen\\b[^_]" lim 'move)
+ (vhdl-re-search-backward ";\\|\\bwhen\\b[^_]" lim 'move)
(or (eq (following-char) ?\;)
(eq (point) lim))))
t)
@@ -5684,7 +5701,7 @@
(cond
((looking-at "is\\|block\\|generate\\|process\\|procedural")
"begin")
- ((looking-at "then")
+ ((looking-at "then\\|use")
"<else>")
(t
"end")))
@@ -5699,6 +5716,9 @@
of an identifier that just happens to contain a \"begin\" keyword."
(save-excursion
(and (looking-at vhdl-begin-fwd-re)
+ (or (not (looking-at "\\<use\\>"))
+ (save-excursion (back-to-indentation)
+ (looking-at
"\\(\\w+\\s-*:\\s-*\\)?\\<\\(case\\|elsif\\|if\\)\\>")))
(/= (preceding-char) ?_)
(not (vhdl-in-literal))
(vhdl-begin-p lim)
@@ -5722,7 +5742,7 @@
(vhdl-backward-skip-label lim)
(vhdl-first-word (point)))))))
;; "component", "units", "record":
- ((looking-at "[cur]")
+ ((looking-at "c\\|un\\|r")
;; The first end found will close the block
(vector "end" nil))
;; "block", "process", "procedural":
@@ -5734,8 +5754,8 @@
(vhdl-backward-skip-label lim)
(vhdl-first-word (point))))))
;; "then":
- ((looking-at "t")
- (vector "elsif\\|else\\|end\\s-+if"
+ ((looking-at "t\\|use")
+ (vector "elsif\\|else\\|end\\s-+\\(if\\|use\\)"
(and (vhdl-last-word (point))
(or (vhdl-first-word (point))
(save-excursion
@@ -5781,7 +5801,7 @@
(vhdl-end-p lim))
(if (looking-at "el")
;; "else", "elsif":
- (vector "if\\|elsif" (vhdl-first-word (point)) "then" nil)
+ (vector "if\\|elsif" (vhdl-first-word (point)) "then\\|use"
nil)
;; "end ...":
(setq pos (point))
(forward-sexp)
@@ -5791,7 +5811,7 @@
((looking-at "if\\b[^_]")
(vector "else\\|elsif\\|if"
(vhdl-first-word pos)
- "else\\|then" nil))
+ "else\\|then\\|use" nil))
;; "end component":
((looking-at "component\\b[^_]")
(vector (buffer-substring (match-beginning 1)
@@ -5879,7 +5899,7 @@
)))
(defconst vhdl-trailer-re
- "\\b\\(is\\|then\\|generate\\|loop\\|record\\)\\b[^_]")
+ "\\b\\(is\\|then\\|generate\\|loop\\|record\\|use\\)\\b[^_]")
(defconst vhdl-statement-fwd-re
"\\b\\(if\\|for\\|while\\)\\b\\([^_]\\|\\'\\)"
@@ -5959,6 +5979,9 @@
(cond
;; "begin" keyword:
((and (looking-at vhdl-begin-fwd-re)
+ (or (not (looking-at "\\<use\\>"))
+ (save-excursion (back-to-indentation)
+ (looking-at
"\\(\\w+\\s-*:\\s-*\\)?\\<\\(case\\|elsif\\|if\\)\\>")))
(/= (preceding-char) ?_)
(vhdl-begin-p lim))
(setq foundp 'begin))
@@ -6058,6 +6081,10 @@
nil
(backward-sexp)
(if (and (looking-at vhdl-begin-fwd-re)
+ (or (not (looking-at "\\<use\\>"))
+ (save-excursion
+ (back-to-indentation)
+ (looking-at "\\(\\w+\\s-*:\\s-*\\)?\\<\\(case\\|elsif\\|if\\)\\>")))
(/= (preceding-char) ?_)
(not (vhdl-in-literal))
(vhdl-begin-p lim))
@@ -6377,6 +6404,10 @@
(setq donep t)))
;; If we are looking at a "begin", then stop
((and (looking-at vhdl-begin-fwd-re)
+ (or (not (looking-at "\\<use\\>"))
+ (save-excursion
+ (back-to-indentation)
+ (looking-at
"\\(\\w+\\s-*:\\s-*\\)?\\<\\(case\\|elsif\\|if\\)\\>")))
(/= (preceding-char) ?_)
(vhdl-begin-p nil))
;; If it's a leader "begin", then find the
@@ -6627,6 +6658,10 @@
(setq begin-after-ip (and
(not literal)
(looking-at vhdl-begin-fwd-re)
+ (or (not (looking-at "\\<use\\>"))
+ (save-excursion
+ (back-to-indentation)
+ (looking-at
"\\(\\w+\\s-*:\\s-*\\)?\\<\\(case\\|elsif\\|if\\)\\>")))
(vhdl-begin-p)))
(setq end-after-ip (and
(not literal)
@@ -6713,6 +6748,9 @@
(save-excursion
(vhdl-beginning-of-statement-1 containing-sexp)
(skip-chars-backward " \t(")
+ (while (= (preceding-char) ?\;)
+ (vhdl-beginning-of-statement-1 containing-sexp)
+ (skip-chars-backward " \t("))
(<= (point) containing-sexp)))
(goto-char containing-sexp)
(vhdl-add-syntax 'arglist-cont-nonempty (vhdl-point 'boi)))
@@ -6994,7 +7032,7 @@
;; Indentation commands
(defun vhdl-electric-tab (&optional prefix-arg)
- "If preceeding character is part of a word or a paren then hippie-expand,
+ "If preceding character is part of a word or a paren then hippie-expand,
else if right of non whitespace on line then insert tab,
else if last command was a tab or return then dedent one step or if a comment
toggle between normal indent and inline comment indent,
@@ -7326,7 +7364,11 @@
(while (< bol end)
(save-excursion
(when (and (re-search-forward match eol t)
- (not (vhdl-in-literal)))
+ (save-excursion
+ (goto-char (match-beginning 0))
+ (and (not (vhdl-in-literal))
+ (not (vhdl-in-quote-p))))
+ (not (looking-at "\\s-*$")))
(setq distance (- (match-beginning substr) bol))
(when (> distance max)
(setq max distance))))
@@ -7341,7 +7383,13 @@
(setq eol (save-excursion (end-of-line) (point)))
(while (> lines 0)
(when (and (re-search-forward match eol t)
- (not (vhdl-in-literal)))
+ (save-excursion
+ (goto-char (match-beginning 0))
+ (and (not (vhdl-in-literal))
+ (not (vhdl-in-quote-p))))
+ (not (looking-at "\\s-*$"))
+ (> (match-beginning 0) ; not if at boi
+ (save-excursion (back-to-indentation) (point))))
(setq width (- (match-end substr) (match-beginning substr)))
(setq distance (- (match-beginning substr) bol))
(goto-char (match-beginning substr))
@@ -7630,7 +7678,7 @@
(while (re-search-forward
"\\(--.*\n\\|\"[^\"\n]*[\"\n]\\|\'.\'\\)\\|\\(\\s-*\\([,;]\\)\\)"
end t)
(if (match-string 1)
(goto-char (match-end 1))
- (replace-match "\\3 " nil nil nil 3)))
+ (replace-match "\\3 " nil nil nil 2)))
;; have no space after `('
(goto-char beg)
(while (re-search-forward
"\\(--.*\n\\|\"[^\"\n]*[\"\n]\\|\'.\'\\)\\|\\((\\)\\s-+"
end t)
@@ -7645,9 +7693,11 @@
(replace-match "\\2")))
;; surround operator symbols by one space
(goto-char beg)
- (while (re-search-forward
"\\(--.*\n\\|\"[^\"\n]*[\"\n]\\|\'.\'\\)\\|\\(\\([^/:<>=]\\)\\(:\\|=\\|<\\|>\\|:=\\|<=\\|>=\\|=>\\|/=\\)\\([^=>]\\|$\\)\\)"
end t)
- (if (match-string 1)
- (goto-char (match-end 1))
+ (while (re-search-forward
"\\(--.*\n\\|\"[^\"\n]*[\"\n]\\|\'.\'\\)\\|\\(\\([^/:<>=]\\)\\(:\\|\\??=\\|\\??<\\|\\??>\\|:=\\|\\??<=\\|\\??>=\\|=>\\|\\??/=\\|\\?\\?\\)\\([^=>]\\|$\\)\\)"
end t)
+ (if (or (match-string 1)
+ (<= (match-beginning 0) ; not if at boi
+ (save-excursion (back-to-indentation) (point))))
+ (goto-char (match-end 0))
(replace-match "\\3 \\4 \\5")
(goto-char (match-end 2))))
;; eliminate multiple spaces and spaces at end of line
@@ -7663,6 +7713,7 @@
(progn (replace-match " " nil nil) t))
(and (looking-at "\\s-+") (re-search-forward "\\s-+" end t)
(progn (replace-match " " nil nil) t))
+ (and (looking-at "-") (re-search-forward "-" end t))
; (re-search-forward "[^ \t-]+" end t))))
(re-search-forward "[^ \t\"-]+" end t))))
(unless no-message (message "Fixing up whitespace...done")))
@@ -7924,8 +7975,8 @@
(goto-char (point-min))
(if (not (re-search-forward (concat "^entity\\s-+" entity-name
"\\>") nil t))
(error "ERROR: Entity \"%s\" not found:\n --> see option
`vhdl-entity-file-name'" entity-name)
- (when (setq beg (re-search-forward
- "^\\s-*port[ \t\n]*("
+ (when (setq beg (vhdl-re-search-forward
+ "\\<port[ \t\n]*("
(save-excursion
(re-search-forward "^end\\>" nil t)) t))
(setq end (save-excursion
@@ -9970,7 +10021,7 @@
(while (search-forward "<standard>" end t)
(replace-match
(concat "VHDL" (cond ((vhdl-standard-p '87) "'87")
- ((vhdl-standard-p '93) "'93"))
+ ((vhdl-standard-p '93) "'93/02"))
(when (vhdl-standard-p 'ams) ", VHDL-AMS")
(when (vhdl-standard-p 'math) ", Math Packages")) t t))
(goto-char beg)
@@ -10455,7 +10506,7 @@
(if vhdl-upper-case-keywords (upcase-word num) (downcase-word num)))
(defun vhdl-minibuffer-tab (&optional prefix-arg)
- "If preceeding character is part of a word or a paren then hippie-expand,
+ "If preceding character is part of a word or a paren then hippie-expand,
else insert tab (used for word completion in VHDL minibuffer)."
(interactive "P")
(cond
@@ -10513,7 +10564,7 @@
(save-excursion
(beginning-of-line)
;; search backward for block beginning or end
- (while (or (while (and (setq pos (re-search-backward
"^\\s-*\\(\\(end\\)\\|\\(\\(impure\\|pure\\)[
\t\n]+\\)?\\(function\\|procedure\\)\\|\\(for\\)\\|\\(architecture\\|component\\|configuration\\|entity\\|package\\|record\\|units\\)\\|\\(\\w+[
\t\n]*:[ \t\n]*\\)?\\(postponed[
\t\n]+\\)?\\(block\\|case\\|for\\|if\\|procedural\\|process\\|while\\)\\)\\>" nil
t))
+ (while (or (while (and (setq pos (re-search-backward
"^\\s-*\\(\\(end\\)\\|\\(\\(impure\\|pure\\)[
\t\n]+\\)?\\(function\\|procedure\\)\\|\\(for\\)\\|\\(architecture\\|component\\|configuration\\|entity\\|package\\(\\s-+body\\)?\\|record\\|units\\)\\|\\(\\w+[
\t\n]*:[ \t\n]*\\)?\\(postponed[
\t\n]+\\)?\\(block\\|case\\|for\\|if\\|procedural\\|process\\|while\\)\\)\\>" nil
t))
;; not consider subprogram declarations
(or (and (match-string 5)
(save-match-data
@@ -10543,7 +10594,7 @@
(save-excursion
(end-of-line)
;; search forward for block beginning or end
- (while (or (while (and (setq pos (re-search-forward
"^\\s-*\\(\\(end\\)\\|\\(\\(impure\\|pure\\)[
\t\n]+\\)?\\(function\\|procedure\\)\\|\\(for\\)\\|\\(architecture\\|component\\|configuration\\|entity\\|package\\|record\\|units\\)\\|\\(\\w+[
\t\n]*:[ \t\n]*\\)?\\(postponed[
\t\n]+\\)?\\(block\\|case\\|for\\|if\\|procedural\\|process\\|while\\)\\)\\>" nil
t))
+ (while (or (while (and (setq pos (re-search-forward
"^\\s-*\\(\\(end\\)\\|\\(\\(impure\\|pure\\)[
\t\n]+\\)?\\(function\\|procedure\\)\\|\\(for\\)\\|\\(architecture\\|component\\|configuration\\|entity\\|package\\(\\s-+body\\)?\\|record\\|units\\)\\|\\(\\w+[
\t\n]*:[ \t\n]*\\)?\\(postponed[
\t\n]+\\)?\\(block\\|case\\|for\\|if\\|procedural\\|process\\|while\\)\\)\\>" nil
t))
;; not consider subprogram declarations
(or (and (match-string 5)
(save-match-data
@@ -13133,7 +13184,7 @@
;; Scan functions
(defun vhdl-scan-context-clause ()
- "Scan the context clause that preceeds a design unit."
+ "Scan the context clause that precedes a design unit."
(let (lib-alist)
(save-excursion
(when (re-search-backward "^[
\t]*\\(architecture\\|configuration\\|entity\\|package\\)\\>" nil t)
@@ -16183,6 +16234,9 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Compilation
+(defvar vhdl-compile-absolute-path nil
+ "If non-nil, use absolute instead of relative path for compiled files.")
+
(defun vhdl-compile-init ()
"Initialize for compilation."
(when (or (null compilation-error-regexp-alist)
@@ -16292,9 +16346,11 @@
(compiler (or (aget vhdl-compiler-alist vhdl-compiler nil)
(error "ERROR: No such compiler: \"%s\"" vhdl-compiler)))
(command (nth 0 compiler))
- (file-name (buffer-file-name))
- (options (vhdl-get-compile-options project compiler file-name))
(default-directory (vhdl-compile-directory))
+ (file-name (if vhdl-compile-absolute-path
+ (buffer-file-name)
+ (file-relative-name (buffer-file-name))))
+ (options (vhdl-get-compile-options project compiler file-name))
compilation-process-setup-function)
(unless (file-directory-p default-directory)
(error "ERROR: Compile directory does not exist: \"%s\""
default-directory))
@@ -16302,7 +16358,9 @@
(when (string-match " " file-name)
(setq file-name (concat "\"" file-name "\"")))
;; print out file name if compiler does not
- (setq vhdl-compile-file-name (buffer-file-name))
+ (setq vhdl-compile-file-name (if vhdl-compile-absolute-path
+ (buffer-file-name)
+ (file-relative-name (buffer-file-name))))
(when (and (= 0 (nth 1 (nth 10 compiler)))
(= 0 (nth 1 (nth 11 compiler))))
(setq compilation-process-setup-function 'vhdl-compile-print-file-name))
@@ -16939,13 +16997,13 @@
Reserved words in VHDL
----------------------
-VHDL'93 (IEEE Std 1076-1993):
- `vhdl-93-keywords' : keywords
- `vhdl-93-types' : standardized types
- `vhdl-93-attributes' : standardized attributes
- `vhdl-93-enum-values' : standardized enumeration values
- `vhdl-93-functions' : standardized functions
- `vhdl-93-packages' : standardized packages and libraries
+VHDL'93/02 (IEEE Std 1076-1993/2002):
+ `vhdl-02-keywords' : keywords
+ `vhdl-02-types' : standardized types
+ `vhdl-02-attributes' : standardized attributes
+ `vhdl-02-enum-values' : standardized enumeration values
+ `vhdl-02-functions' : standardized functions
+ `vhdl-02-packages' : standardized packages and libraries
VHDL-AMS (IEEE Std 1076.1):
`vhdl-ams-keywords' : keywords
Index: xemacs-packages/vhdl/vhdl-mode.texi
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/vhdl/vhdl-mode.texi,v
retrieving revision 1.6
diff -d -u -r1.6 vhdl-mode.texi
--- xemacs-packages/vhdl/vhdl-mode.texi 2002/01/14 07:59:57 1.6
+++ xemacs-packages/vhdl/vhdl-mode.texi 2006/08/09 16:03:13
@@ -147,7 +147,7 @@
This manual is not very up-to-date. It basically contains the
indentation machine documentation by Rod Whitby with only minor
adaptions. A short documentation of the entire VHDL Mode is available
-within the mode itself by typing @kbd{C-c C-h}. Also, all commands and
+within the mode itself by typing @kbd{C-c C-h}. Also, all commands and the
customization of most variables is available through the menu, which
makes everything highly self-explaining.
Index: xemacs-packages/vhdl/Makefile
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/vhdl/Makefile,v
retrieving revision 1.32
diff -d -u -r1.32 Makefile
--- xemacs-packages/vhdl/Makefile 2006/04/19 06:15:04 1.32
+++ xemacs-packages/vhdl/Makefile 2006/08/09 16:03:13
@@ -18,7 +18,7 @@
# Boston, MA 02111-1307, USA.
VERSION = 1.21
-AUTHOR_VERSION = 3.33.8
+AUTHOR_VERSION = 3.33.12
MAINTAINER = XEmacs Development Team <xemacs-beta(a)xemacs.org>
PACKAGE = vhdl
PKG_TYPE = regular
--
Jerry James, Assistant Professor james(a)xemacs.org
Computer Science Department
http://www.cs.usu.edu/~jerry/
Utah State University