diff options
| author | Miles Bader | 2005-05-26 05:42:19 +0000 |
|---|---|---|
| committer | Miles Bader | 2005-05-26 05:42:19 +0000 |
| commit | d2eeec7fb90dc54c4b08e85f452a23317c0ee65d (patch) | |
| tree | cd13677b902ee91ff96c5f43ca30ae2aba828312 /lisp/progmodes | |
| parent | 5611ba87dd81c98d2cc00a4d01e19db3d26cf9d5 (diff) | |
| parent | c0e9b2d0ec9cb343733243371efecf77722b067f (diff) | |
| download | emacs-d2eeec7fb90dc54c4b08e85f452a23317c0ee65d.tar.gz emacs-d2eeec7fb90dc54c4b08e85f452a23317c0ee65d.zip | |
Revision: miles@gnu.org--gnu-2005/emacs--unicode--0--patch-55
Merge from emacs--cvs-trunk--0
Patches applied:
* emacs--cvs-trunk--0 (patch 320-323)
- Update from CVS
Diffstat (limited to 'lisp/progmodes')
| -rw-r--r-- | lisp/progmodes/cc-align.el | 10 | ||||
| -rw-r--r-- | lisp/progmodes/cc-awk.el | 19 | ||||
| -rw-r--r-- | lisp/progmodes/cc-cmds.el | 9 | ||||
| -rw-r--r-- | lisp/progmodes/cc-defs.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/cc-engine.el | 34 | ||||
| -rw-r--r-- | lisp/progmodes/cc-fonts.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/cc-langs.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/cc-mode.el | 38 | ||||
| -rw-r--r-- | lisp/progmodes/cc-styles.el | 1 | ||||
| -rw-r--r-- | lisp/progmodes/cperl-mode.el | 23 | ||||
| -rw-r--r-- | lisp/progmodes/etags.el | 3 | ||||
| -rw-r--r-- | lisp/progmodes/flymake.el | 3 | ||||
| -rw-r--r-- | lisp/progmodes/gdb-ui.el | 26 | ||||
| -rw-r--r-- | lisp/progmodes/idlwave.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/make-mode.el | 14 | ||||
| -rw-r--r-- | lisp/progmodes/sh-script.el | 4 | ||||
| -rw-r--r-- | lisp/progmodes/vhdl-mode.el | 6 |
17 files changed, 128 insertions, 70 deletions
diff --git a/lisp/progmodes/cc-align.el b/lisp/progmodes/cc-align.el index c5dd091f291..139bfc8aa5a 100644 --- a/lisp/progmodes/cc-align.el +++ b/lisp/progmodes/cc-align.el | |||
| @@ -24,9 +24,9 @@ | |||
| 24 | ;; GNU General Public License for more details. | 24 | ;; GNU General Public License for more details. |
| 25 | 25 | ||
| 26 | ;; You should have received a copy of the GNU General Public License | 26 | ;; You should have received a copy of the GNU General Public License |
| 27 | ;; along with GNU Emacs; see the file COPYING. If not, write to | 27 | ;; along with this program; see the file COPYING. If not, write to |
| 28 | ;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 28 | ;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 29 | ;; Boston, MA 02111-1307, USA. | 29 | ;; Boston, MA 02110-1301, USA. |
| 30 | 30 | ||
| 31 | ;;; Commentary: | 31 | ;;; Commentary: |
| 32 | 32 | ||
| @@ -175,7 +175,8 @@ Works with: arglist-cont, arglist-cont-nonempty." | |||
| 175 | (let ((open-paren (elt c-syntactic-element 2)) | 175 | (let ((open-paren (elt c-syntactic-element 2)) |
| 176 | (paren-state (c-parse-state))) | 176 | (paren-state (c-parse-state))) |
| 177 | (while (not (eq (car paren-state) open-paren)) | 177 | (while (not (eq (car paren-state) open-paren)) |
| 178 | (goto-char (car paren-state)) | 178 | (unless (consp (car paren-state)) ;; ignore matched braces |
| 179 | (goto-char (car paren-state))) | ||
| 179 | (setq paren-state (cdr paren-state))))) | 180 | (setq paren-state (cdr paren-state))))) |
| 180 | 181 | ||
| 181 | (let ((start (point)) c) | 182 | (let ((start (point)) c) |
| @@ -1171,6 +1172,7 @@ Otherwise, no determination is made." | |||
| 1171 | ;;(/= (point-max) | 1172 | ;;(/= (point-max) |
| 1172 | ;; (save-excursion (skip-syntax-forward " ") (point)) | 1173 | ;; (save-excursion (skip-syntax-forward " ") (point)) |
| 1173 | (zerop (forward-line 1)) | 1174 | (zerop (forward-line 1)) |
| 1175 | (bolp) ; forward-line has funny behavior at eob. | ||
| 1174 | (not (looking-at "^[ \t]*$"))) | 1176 | (not (looking-at "^[ \t]*$"))) |
| 1175 | 'stop | 1177 | 'stop |
| 1176 | nil))) | 1178 | nil))) |
diff --git a/lisp/progmodes/cc-awk.el b/lisp/progmodes/cc-awk.el index dbcfa9d991e..419803a7ada 100644 --- a/lisp/progmodes/cc-awk.el +++ b/lisp/progmodes/cc-awk.el | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1988,94,96,2000,01,02,03 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1988,94,96,2000,01,02,03 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Alan Mackenzie (originally based on awk-mode.el) | 5 | ;; Author: Alan Mackenzie <acm@muc.de> (originally based on awk-mode.el) |
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: FSF |
| 7 | ;; Keywords: AWK, cc-mode, unix, languages | 7 | ;; Keywords: AWK, cc-mode, unix, languages |
| 8 | 8 | ||
| @@ -526,13 +526,22 @@ | |||
| 526 | ;; Matches any AWK regexp character which doesn't require special analysis. | 526 | ;; Matches any AWK regexp character which doesn't require special analysis. |
| 527 | (defconst c-awk-escaped-newlines*-re "\\(\\\\[\n\r]\\)*") | 527 | (defconst c-awk-escaped-newlines*-re "\\(\\\\[\n\r]\\)*") |
| 528 | ;; Matches a (possibly empty) sequence of escaped newlines. | 528 | ;; Matches a (possibly empty) sequence of escaped newlines. |
| 529 | |||
| 530 | ;; NOTE: In what follows, "[asdf]" in a regexp will be called a "character | ||
| 531 | ;; list", and "[:alpha:]" inside a character list will be known as a | ||
| 532 | ;; "character class". These terms for these things vary between regexp | ||
| 533 | ;; descriptions . | ||
| 529 | (defconst c-awk-regexp-char-class-re | 534 | (defconst c-awk-regexp-char-class-re |
| 535 | "\\[:[a-z]+:\\]") | ||
| 536 | ;; Matches a character class spec (e.g. [:alpha:]). | ||
| 537 | (defconst c-awk-regexp-char-list-re | ||
| 530 | (concat "\\[" c-awk-escaped-newlines*-re "^?" c-awk-escaped-newlines*-re "]?" | 538 | (concat "\\[" c-awk-escaped-newlines*-re "^?" c-awk-escaped-newlines*-re "]?" |
| 531 | "\\(" c-awk-esc-pair-re "\\|" "[^]\n\r]" "\\)*" "\\(]\\|$\\)")) | 539 | "\\(" c-awk-esc-pair-re "\\|" c-awk-regexp-char-class-re |
| 532 | ;; Matches a regexp char class, up to (but not including) EOL if the ] is | 540 | "\\|" "[^]\n\r]" "\\)*" "\\(]\\|$\\)")) |
| 541 | ;; Matches a regexp char list, up to (but not including) EOL if the ] is | ||
| 533 | ;; missing. | 542 | ;; missing. |
| 534 | (defconst c-awk-regexp-innards-re | 543 | (defconst c-awk-regexp-innards-re |
| 535 | (concat "\\(" c-awk-esc-pair-re "\\|" c-awk-regexp-char-class-re | 544 | (concat "\\(" c-awk-esc-pair-re "\\|" c-awk-regexp-char-list-re |
| 536 | "\\|" c-awk-regexp-normal-re "\\)*")) | 545 | "\\|" c-awk-regexp-normal-re "\\)*")) |
| 537 | ;; Matches the inside of an AWK regexp (i.e. without the enclosing /s) | 546 | ;; Matches the inside of an AWK regexp (i.e. without the enclosing /s) |
| 538 | (defconst c-awk-regexp-without-end-re | 547 | (defconst c-awk-regexp-without-end-re |
| @@ -549,7 +558,7 @@ | |||
| 549 | ;; A "neutral" char(pair). Doesn't change the "state" of a subsequent /. | 558 | ;; A "neutral" char(pair). Doesn't change the "state" of a subsequent /. |
| 550 | ;; This is space/tab, braces, an auto-increment/decrement operator or an | 559 | ;; This is space/tab, braces, an auto-increment/decrement operator or an |
| 551 | ;; escaped character. Or one of the (illegal) characters @ or `. But NOT an | 560 | ;; escaped character. Or one of the (illegal) characters @ or `. But NOT an |
| 552 | ;; end of line (even if escpaed). | 561 | ;; end of line (even if escaped). |
| 553 | (defconst c-awk-neutrals*-re | 562 | (defconst c-awk-neutrals*-re |
| 554 | (concat "\\(" c-awk-neutral-re "\\)*")) | 563 | (concat "\\(" c-awk-neutral-re "\\)*")) |
| 555 | ;; A (possibly empty) string of neutral characters (or character pairs). | 564 | ;; A (possibly empty) string of neutral characters (or character pairs). |
diff --git a/lisp/progmodes/cc-cmds.el b/lisp/progmodes/cc-cmds.el index 806fbade693..7be8e370f07 100644 --- a/lisp/progmodes/cc-cmds.el +++ b/lisp/progmodes/cc-cmds.el | |||
| @@ -2441,7 +2441,8 @@ command to conveniently insert and align the necessary backslashes." | |||
| 2441 | (delete-region (point) end) | 2441 | (delete-region (point) end) |
| 2442 | (indent-to column 1))) | 2442 | (indent-to column 1))) |
| 2443 | 2443 | ||
| 2444 | (= (forward-line 1) 0)))) | 2444 | (zerop (forward-line 1))) |
| 2445 | (bolp))) ; forward-line has funny behavior at eob. | ||
| 2445 | 2446 | ||
| 2446 | ;; Make sure there are backslashes with at least one space in | 2447 | ;; Make sure there are backslashes with at least one space in |
| 2447 | ;; front of them. | 2448 | ;; front of them. |
| @@ -2466,7 +2467,8 @@ command to conveniently insert and align the necessary backslashes." | |||
| 2466 | (insert ?\\) | 2467 | (insert ?\\) |
| 2467 | (insert ?\ ?\\))) | 2468 | (insert ?\ ?\\))) |
| 2468 | 2469 | ||
| 2469 | (= (forward-line 1) 0))))))) | 2470 | (zerop (forward-line 1))) |
| 2471 | (bolp)))))) ; forward-line has funny behavior at eob. | ||
| 2470 | 2472 | ||
| 2471 | (defun c-delete-backslashes-forward (to-mark point-pos) | 2473 | (defun c-delete-backslashes-forward (to-mark point-pos) |
| 2472 | ;; This function does not do any hidden buffer changes. | 2474 | ;; This function does not do any hidden buffer changes. |
| @@ -2481,7 +2483,8 @@ command to conveniently insert and align the necessary backslashes." | |||
| 2481 | (skip-chars-backward " \t" (if (>= (point) point-pos) | 2483 | (skip-chars-backward " \t" (if (>= (point) point-pos) |
| 2482 | point-pos)) | 2484 | point-pos)) |
| 2483 | (point)))) | 2485 | (point)))) |
| 2484 | (= (forward-line 1) 0))))) | 2486 | (zerop (forward-line 1))) |
| 2487 | (bolp)))) ; forward-line has funny behavior at eob. | ||
| 2485 | 2488 | ||
| 2486 | 2489 | ||
| 2487 | 2490 | ||
diff --git a/lisp/progmodes/cc-defs.el b/lisp/progmodes/cc-defs.el index 64f3a72f56f..d9caca90666 100644 --- a/lisp/progmodes/cc-defs.el +++ b/lisp/progmodes/cc-defs.el | |||
| @@ -104,7 +104,7 @@ | |||
| 104 | 104 | ||
| 105 | ;;; Variables also used at compile time. | 105 | ;;; Variables also used at compile time. |
| 106 | 106 | ||
| 107 | (defconst c-version "5.30.9" | 107 | (defconst c-version "5.30.10" |
| 108 | "CC Mode version number.") | 108 | "CC Mode version number.") |
| 109 | 109 | ||
| 110 | (defconst c-version-sym (intern c-version)) | 110 | (defconst c-version-sym (intern c-version)) |
diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 0a4cb6c8cd6..e9ed474e792 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el | |||
| @@ -24,9 +24,9 @@ | |||
| 24 | ;; GNU General Public License for more details. | 24 | ;; GNU General Public License for more details. |
| 25 | 25 | ||
| 26 | ;; You should have received a copy of the GNU General Public License | 26 | ;; You should have received a copy of the GNU General Public License |
| 27 | ;; along with GNU Emacs; see the file COPYING. If not, write to | 27 | ;; along with this program; see the file COPYING. If not, write to |
| 28 | ;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 28 | ;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 29 | ;; Boston, MA 02111-1307, USA. | 29 | ;; Boston, MA 02110-1301, USA. |
| 30 | 30 | ||
| 31 | ;;; Commentary: | 31 | ;;; Commentary: |
| 32 | 32 | ||
| @@ -3198,6 +3198,7 @@ This function does not do any hidden buffer changes." | |||
| 3198 | ;; when font-lock refontifies the current line only. | 3198 | ;; when font-lock refontifies the current line only. |
| 3199 | (when (save-excursion | 3199 | (when (save-excursion |
| 3200 | (and (= (forward-line 1) 0) | 3200 | (and (= (forward-line 1) 0) |
| 3201 | (bolp) ; forward-line has funny behavior at eob. | ||
| 3201 | (or (< (c-point 'eol) cfd-limit) | 3202 | (or (< (c-point 'eol) cfd-limit) |
| 3202 | (progn (backward-char) | 3203 | (progn (backward-char) |
| 3203 | (not (eq (char-before) ?\\)))))) | 3204 | (not (eq (char-before) ?\\)))))) |
| @@ -4551,7 +4552,7 @@ brace." | |||
| 4551 | ;; operator token preceded by "operator". | 4552 | ;; operator token preceded by "operator". |
| 4552 | (save-excursion | 4553 | (save-excursion |
| 4553 | (and (c-safe (c-backward-sexp) t) | 4554 | (and (c-safe (c-backward-sexp) t) |
| 4554 | (looking-at "operator\\([^_]\\|$\\)"))) | 4555 | (looking-at "operator\\>\\([^_]\\|$\\)"))) |
| 4555 | (and (eq (char-before) ?<) | 4556 | (and (eq (char-before) ?<) |
| 4556 | (c-with-syntax-table c++-template-syntax-table | 4557 | (c-with-syntax-table c++-template-syntax-table |
| 4557 | (if (c-safe (goto-char (c-up-list-forward (point)))) | 4558 | (if (c-safe (goto-char (c-up-list-forward (point)))) |
| @@ -6104,7 +6105,12 @@ This function does not do any hidden buffer changes." | |||
| 6104 | ;; Note: We use the fact that lim is always after any | 6105 | ;; Note: We use the fact that lim is always after any |
| 6105 | ;; preceding brace sexp. | 6106 | ;; preceding brace sexp. |
| 6106 | (while (and (zerop (c-backward-token-2 1 t lim)) | 6107 | (while (and (zerop (c-backward-token-2 1 t lim)) |
| 6107 | (not (looking-at "[;<,=]")))) | 6108 | (or (not (looking-at "[;<,=]")) |
| 6109 | (and c-overloadable-operators-regexp | ||
| 6110 | (looking-at c-overloadable-operators-regexp) | ||
| 6111 | (save-excursion | ||
| 6112 | (c-backward-token-2 1 nil lim) | ||
| 6113 | (looking-at "operator\\>[^_]")))))) | ||
| 6108 | (or (memq (char-after) '(?, ?=)) | 6114 | (or (memq (char-after) '(?, ?=)) |
| 6109 | (and (c-major-mode-is 'c++-mode) | 6115 | (and (c-major-mode-is 'c++-mode) |
| 6110 | (zerop (c-backward-token-2 1 nil lim)) | 6116 | (zerop (c-backward-token-2 1 nil lim)) |
| @@ -6237,7 +6243,15 @@ This function does not do any hidden buffer changes." | |||
| 6237 | ;; CASE 5I: ObjC method definition. | 6243 | ;; CASE 5I: ObjC method definition. |
| 6238 | ((and c-opt-method-key | 6244 | ((and c-opt-method-key |
| 6239 | (looking-at c-opt-method-key)) | 6245 | (looking-at c-opt-method-key)) |
| 6240 | (c-beginning-of-statement-1 lim) | 6246 | (c-beginning-of-statement-1 nil t) |
| 6247 | (if (= (point) indent-point) | ||
| 6248 | ;; Handle the case when it's the first (non-comment) | ||
| 6249 | ;; thing in the buffer. Can't look for a 'same return | ||
| 6250 | ;; value from cbos1 since ObjC directives currently | ||
| 6251 | ;; aren't recognized fully, so that we get 'same | ||
| 6252 | ;; instead of 'previous if it moved over a preceding | ||
| 6253 | ;; directive. | ||
| 6254 | (goto-char (point-min))) | ||
| 6241 | (c-add-syntax 'objc-method-intro (c-point 'boi))) | 6255 | (c-add-syntax 'objc-method-intro (c-point 'boi))) |
| 6242 | ;; CASE 5P: AWK pattern or function or continuation | 6256 | ;; CASE 5P: AWK pattern or function or continuation |
| 6243 | ;; thereof. | 6257 | ;; thereof. |
| @@ -6316,11 +6330,13 @@ This function does not do any hidden buffer changes." | |||
| 6316 | ;; CASE 5K: we are at an ObjC method definition | 6330 | ;; CASE 5K: we are at an ObjC method definition |
| 6317 | ;; continuation line. | 6331 | ;; continuation line. |
| 6318 | ((and c-opt-method-key | 6332 | ((and c-opt-method-key |
| 6319 | (progn | 6333 | (save-excursion |
| 6334 | (goto-char indent-point) | ||
| 6320 | (c-beginning-of-statement-1 lim) | 6335 | (c-beginning-of-statement-1 lim) |
| 6321 | (beginning-of-line) | 6336 | (beginning-of-line) |
| 6322 | (looking-at c-opt-method-key))) | 6337 | (when (looking-at c-opt-method-key) |
| 6323 | (c-add-syntax 'objc-method-args-cont (point))) | 6338 | (setq placeholder (point))))) |
| 6339 | (c-add-syntax 'objc-method-args-cont placeholder)) | ||
| 6324 | ;; CASE 5L: we are at the first argument of a template | 6340 | ;; CASE 5L: we are at the first argument of a template |
| 6325 | ;; arglist that begins on the previous line. | 6341 | ;; arglist that begins on the previous line. |
| 6326 | ((eq (char-before) ?<) | 6342 | ((eq (char-before) ?<) |
diff --git a/lisp/progmodes/cc-fonts.el b/lisp/progmodes/cc-fonts.el index 26c0bdaf60f..29946dc4682 100644 --- a/lisp/progmodes/cc-fonts.el +++ b/lisp/progmodes/cc-fonts.el | |||
| @@ -875,7 +875,7 @@ casts and declarations are fontified. Used on level 2 and higher." | |||
| 875 | ;; with array initializers. Otherwise stop at braces | 875 | ;; with array initializers. Otherwise stop at braces |
| 876 | ;; to avoid going past full function and class blocks. | 876 | ;; to avoid going past full function and class blocks. |
| 877 | (and (if (and (eq got-init ?=) | 877 | (and (if (and (eq got-init ?=) |
| 878 | (= (c-forward-token-2) 0) | 878 | (= (c-forward-token-2 1 nil limit) 0) |
| 879 | (looking-at "{")) | 879 | (looking-at "{")) |
| 880 | (c-safe (c-forward-sexp) t) | 880 | (c-safe (c-forward-sexp) t) |
| 881 | t) | 881 | t) |
diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el index 6a36f89c8d3..94d58c66061 100644 --- a/lisp/progmodes/cc-langs.el +++ b/lisp/progmodes/cc-langs.el | |||
| @@ -1186,7 +1186,7 @@ will be handled." | |||
| 1186 | (c-lang-defvar c-brace-list-key (c-lang-const c-brace-list-key)) | 1186 | (c-lang-defvar c-brace-list-key (c-lang-const c-brace-list-key)) |
| 1187 | 1187 | ||
| 1188 | (c-lang-defconst c-other-block-decl-kwds | 1188 | (c-lang-defconst c-other-block-decl-kwds |
| 1189 | "Keywords where the following block (if any) contain another | 1189 | "Keywords where the following block (if any) contains another |
| 1190 | declaration level that should not be considered a class. | 1190 | declaration level that should not be considered a class. |
| 1191 | 1191 | ||
| 1192 | If any of these also are on `c-type-list-kwds', `c-ref-list-kwds', | 1192 | If any of these also are on `c-type-list-kwds', `c-ref-list-kwds', |
diff --git a/lisp/progmodes/cc-mode.el b/lisp/progmodes/cc-mode.el index eaa798217cf..0f17a003ef4 100644 --- a/lisp/progmodes/cc-mode.el +++ b/lisp/progmodes/cc-mode.el | |||
| @@ -24,9 +24,9 @@ | |||
| 24 | ;; GNU General Public License for more details. | 24 | ;; GNU General Public License for more details. |
| 25 | 25 | ||
| 26 | ;; You should have received a copy of the GNU General Public License | 26 | ;; You should have received a copy of the GNU General Public License |
| 27 | ;; along with GNU Emacs; see the file COPYING. If not, write to | 27 | ;; along with this program; see the file COPYING. If not, write to |
| 28 | ;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 28 | ;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 29 | ;; Boston, MA 02111-1307, USA. | 29 | ;; Boston, MA 02110-1301, USA. |
| 30 | 30 | ||
| 31 | ;;; Commentary: | 31 | ;;; Commentary: |
| 32 | 32 | ||
| @@ -91,10 +91,12 @@ | |||
| 91 | (cc-require 'cc-align) | 91 | (cc-require 'cc-align) |
| 92 | (cc-require 'cc-menus) | 92 | (cc-require 'cc-menus) |
| 93 | 93 | ||
| 94 | ;; SILENCE the compiler. | 94 | ;; Silence the compiler. |
| 95 | (cc-bytecomp-defvar comment-line-break-function) ; (X)Emacs 20+ | 95 | (cc-bytecomp-defvar comment-line-break-function) ; (X)Emacs 20+ |
| 96 | (cc-bytecomp-defvar adaptive-fill-first-line-regexp) ; Emacs 20+ | 96 | (cc-bytecomp-defvar adaptive-fill-first-line-regexp) ; Emacs 20+ |
| 97 | (cc-bytecomp-defun set-keymap-parents) ; XEmacs | 97 | (cc-bytecomp-defun set-keymap-parents) ; XEmacs |
| 98 | (cc-bytecomp-defun run-mode-hooks) ; Emacs 21.1+ | ||
| 99 | (cc-bytecomp-obsolete-fun make-local-hook) ; Marked obsolete in Emacs 21.1. | ||
| 98 | 100 | ||
| 99 | ;; We set these variables during mode init, yet we don't require | 101 | ;; We set these variables during mode init, yet we don't require |
| 100 | ;; font-lock. | 102 | ;; font-lock. |
| @@ -201,12 +203,15 @@ control). See \"cc-mode.el\" for more info." | |||
| 201 | 203 | ||
| 202 | (defun c-make-inherited-keymap () | 204 | (defun c-make-inherited-keymap () |
| 203 | (let ((map (make-sparse-keymap))) | 205 | (let ((map (make-sparse-keymap))) |
| 206 | ;; Necessary to use `cc-bytecomp-fboundp' below since this | ||
| 207 | ;; function is called from top-level forms that are evaluated | ||
| 208 | ;; while cc-bytecomp is active when one does M-x eval-buffer. | ||
| 204 | (cond | 209 | (cond |
| 205 | ;; XEmacs | 210 | ;; XEmacs |
| 206 | ((fboundp 'set-keymap-parents) | 211 | ((cc-bytecomp-fboundp 'set-keymap-parents) |
| 207 | (set-keymap-parents map c-mode-base-map)) | 212 | (set-keymap-parents map c-mode-base-map)) |
| 208 | ;; Emacs | 213 | ;; Emacs |
| 209 | ((fboundp 'set-keymap-parent) | 214 | ((cc-bytecomp-fboundp 'set-keymap-parent) |
| 210 | (set-keymap-parent map c-mode-base-map)) | 215 | (set-keymap-parent map c-mode-base-map)) |
| 211 | ;; incompatible | 216 | ;; incompatible |
| 212 | (t (error "CC Mode is incompatible with this version of Emacs"))) | 217 | (t (error "CC Mode is incompatible with this version of Emacs"))) |
| @@ -587,6 +592,13 @@ Note that the style variables are always made local to the buffer." | |||
| 587 | 592 | ||
| 588 | (add-hook 'hack-local-variables-hook 'c-postprocess-file-styles) | 593 | (add-hook 'hack-local-variables-hook 'c-postprocess-file-styles) |
| 589 | 594 | ||
| 595 | (defmacro c-run-mode-hooks (&rest hooks) | ||
| 596 | ;; Emacs 21.1 has introduced a system with delayed mode hooks that | ||
| 597 | ;; require the use of the new function `run-mode-hooks'. | ||
| 598 | (if (cc-bytecomp-fboundp 'run-mode-hooks) | ||
| 599 | `(run-mode-hooks ,@hooks) | ||
| 600 | `(progn ,@(mapcar (lambda (hook) `(run-hooks ,hook)) hooks)))) | ||
| 601 | |||
| 590 | 602 | ||
| 591 | ;; Support for C | 603 | ;; Support for C |
| 592 | 604 | ||
| @@ -667,7 +679,7 @@ Key bindings: | |||
| 667 | (c-common-init 'c-mode) | 679 | (c-common-init 'c-mode) |
| 668 | (easy-menu-add c-c-menu) | 680 | (easy-menu-add c-c-menu) |
| 669 | (cc-imenu-init cc-imenu-c-generic-expression) | 681 | (cc-imenu-init cc-imenu-c-generic-expression) |
| 670 | (run-mode-hooks 'c-mode-common-hook 'c-mode-hook) | 682 | (c-run-mode-hooks 'c-mode-common-hook 'c-mode-hook) |
| 671 | (c-update-modeline)) | 683 | (c-update-modeline)) |
| 672 | 684 | ||
| 673 | 685 | ||
| @@ -730,7 +742,7 @@ Key bindings: | |||
| 730 | (c-common-init 'c++-mode) | 742 | (c-common-init 'c++-mode) |
| 731 | (easy-menu-add c-c++-menu) | 743 | (easy-menu-add c-c++-menu) |
| 732 | (cc-imenu-init cc-imenu-c++-generic-expression) | 744 | (cc-imenu-init cc-imenu-c++-generic-expression) |
| 733 | (run-mode-hooks 'c-mode-common-hook 'c++-mode-hook) | 745 | (c-run-mode-hooks 'c-mode-common-hook 'c++-mode-hook) |
| 734 | (c-update-modeline)) | 746 | (c-update-modeline)) |
| 735 | 747 | ||
| 736 | 748 | ||
| @@ -794,7 +806,7 @@ Key bindings: | |||
| 794 | (c-common-init 'objc-mode) | 806 | (c-common-init 'objc-mode) |
| 795 | (easy-menu-add c-objc-menu) | 807 | (easy-menu-add c-objc-menu) |
| 796 | (cc-imenu-init nil 'cc-imenu-objc-function) | 808 | (cc-imenu-init nil 'cc-imenu-objc-function) |
| 797 | (run-mode-hooks 'c-mode-common-hook 'objc-mode-hook) | 809 | (c-run-mode-hooks 'c-mode-common-hook 'objc-mode-hook) |
| 798 | (c-update-modeline)) | 810 | (c-update-modeline)) |
| 799 | 811 | ||
| 800 | 812 | ||
| @@ -864,7 +876,7 @@ Key bindings: | |||
| 864 | (c-common-init 'java-mode) | 876 | (c-common-init 'java-mode) |
| 865 | (easy-menu-add c-java-menu) | 877 | (easy-menu-add c-java-menu) |
| 866 | (cc-imenu-init cc-imenu-java-generic-expression) | 878 | (cc-imenu-init cc-imenu-java-generic-expression) |
| 867 | (run-mode-hooks 'c-mode-common-hook 'java-mode-hook) | 879 | (c-run-mode-hooks 'c-mode-common-hook 'java-mode-hook) |
| 868 | (c-update-modeline)) | 880 | (c-update-modeline)) |
| 869 | 881 | ||
| 870 | 882 | ||
| @@ -922,7 +934,7 @@ Key bindings: | |||
| 922 | (c-common-init 'idl-mode) | 934 | (c-common-init 'idl-mode) |
| 923 | (easy-menu-add c-idl-menu) | 935 | (easy-menu-add c-idl-menu) |
| 924 | ;;(cc-imenu-init cc-imenu-idl-generic-expression) ;TODO | 936 | ;;(cc-imenu-init cc-imenu-idl-generic-expression) ;TODO |
| 925 | (run-mode-hooks 'c-mode-common-hook 'idl-mode-hook) | 937 | (c-run-mode-hooks 'c-mode-common-hook 'idl-mode-hook) |
| 926 | (c-update-modeline)) | 938 | (c-update-modeline)) |
| 927 | 939 | ||
| 928 | 940 | ||
| @@ -984,7 +996,7 @@ Key bindings: | |||
| 984 | (c-common-init 'pike-mode) | 996 | (c-common-init 'pike-mode) |
| 985 | (easy-menu-add c-pike-menu) | 997 | (easy-menu-add c-pike-menu) |
| 986 | ;;(cc-imenu-init cc-imenu-pike-generic-expression) ;TODO | 998 | ;;(cc-imenu-init cc-imenu-pike-generic-expression) ;TODO |
| 987 | (run-mode-hooks 'c-mode-common-hook 'pike-mode-hook) | 999 | (c-run-mode-hooks 'c-mode-common-hook 'pike-mode-hook) |
| 988 | (c-update-modeline)) | 1000 | (c-update-modeline)) |
| 989 | 1001 | ||
| 990 | 1002 | ||
| @@ -1076,7 +1088,7 @@ Key bindings: | |||
| 1076 | ;; in cc-engine.el, just before (defun c-fast-in-literal ... | 1088 | ;; in cc-engine.el, just before (defun c-fast-in-literal ... |
| 1077 | (defalias 'c-in-literal 'c-slow-in-literal) | 1089 | (defalias 'c-in-literal 'c-slow-in-literal) |
| 1078 | 1090 | ||
| 1079 | (run-mode-hooks 'c-mode-common-hook 'awk-mode-hook) | 1091 | (c-run-mode-hooks 'c-mode-common-hook 'awk-mode-hook) |
| 1080 | (c-update-modeline)) | 1092 | (c-update-modeline)) |
| 1081 | ) ;; closes the (if (not (memq 'syntax-properties c-emacs-features)) | 1093 | ) ;; closes the (if (not (memq 'syntax-properties c-emacs-features)) |
| 1082 | 1094 | ||
diff --git a/lisp/progmodes/cc-styles.el b/lisp/progmodes/cc-styles.el index 1a26e54bf06..14f988feb03 100644 --- a/lisp/progmodes/cc-styles.el +++ b/lisp/progmodes/cc-styles.el | |||
| @@ -48,6 +48,7 @@ | |||
| 48 | 48 | ||
| 49 | ;; Silence the compiler. | 49 | ;; Silence the compiler. |
| 50 | (cc-bytecomp-defvar adaptive-fill-first-line-regexp) ; Emacs | 50 | (cc-bytecomp-defvar adaptive-fill-first-line-regexp) ; Emacs |
| 51 | (cc-bytecomp-obsolete-fun make-local-hook) ; Marked obsolete in Emacs 21.1. | ||
| 51 | 52 | ||
| 52 | 53 | ||
| 53 | (defvar c-style-alist | 54 | (defvar c-style-alist |
diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index 436bc04d044..4abd8123e6a 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el | |||
| @@ -342,10 +342,19 @@ Affects: `cperl-font-lock', `cperl-electric-lbrace-space', | |||
| 342 | :type 'integer | 342 | :type 'integer |
| 343 | :group 'cperl-indentation-details) | 343 | :group 'cperl-indentation-details) |
| 344 | 344 | ||
| 345 | (defcustom cperl-vc-header-alist '((SCCS "($sccs) = ('%W\%' =~ /(\\d+(\\.\\d+)+)/) ;") | 345 | (defvar cperl-vc-header-alist nil) |
| 346 | (RCS "($rcs) = (' $Id\$ ' =~ /(\\d+(\\.\\d+)+)/) ;")) | 346 | (make-obsolete-variable |
| 347 | "*What to use as `vc-header-alist' in CPerl." | 347 | 'cperl-vc-header-alist |
| 348 | :type '(repeat (list symbol string)) | 348 | "use cperl-vc-rcs-header or cperl-vc-sccs-header instead.") |
| 349 | |||
| 350 | (defcustom cperl-vc-sccs-header '("($sccs) = ('%W\%' =~ /(\\d+(\\.\\d+)+)/) ;") | ||
| 351 | "*Special version of `vc-sccs-header' that is used in CPerl mode buffers." | ||
| 352 | :type '(repeat string) | ||
| 353 | :group 'cperl) | ||
| 354 | |||
| 355 | (defcustom cperl-vc-rcs-header '("($rcs) = (' $Id\$ ' =~ /(\\d+(\\.\\d+)+)/) ;") | ||
| 356 | "*Special version of `vc-rcs-header' that is used in CPerl mode buffers." | ||
| 357 | :type '(repeat string) | ||
| 349 | :group 'cperl) | 358 | :group 'cperl) |
| 350 | 359 | ||
| 351 | (defcustom cperl-clobber-mode-lists | 360 | (defcustom cperl-clobber-mode-lists |
| @@ -1485,8 +1494,10 @@ or as help on variables `cperl-tips', `cperl-problems', | |||
| 1485 | (function cperl-imenu--create-perl-index)) | 1494 | (function cperl-imenu--create-perl-index)) |
| 1486 | (make-local-variable 'imenu-sort-function) | 1495 | (make-local-variable 'imenu-sort-function) |
| 1487 | (setq imenu-sort-function nil) | 1496 | (setq imenu-sort-function nil) |
| 1488 | (make-local-variable 'vc-header-alist) | 1497 | (make-local-variable 'vc-rcs-header) |
| 1489 | (set 'vc-header-alist cperl-vc-header-alist) ; Avoid warning | 1498 | (set 'vc-rcs-header cperl-vc-rcs-header) |
| 1499 | (make-local-variable 'vc-sccs-header) | ||
| 1500 | (set 'vc-sccs-header cperl-vc-sccs-header) | ||
| 1490 | (make-local-variable 'font-lock-defaults) | 1501 | (make-local-variable 'font-lock-defaults) |
| 1491 | (setq font-lock-defaults | 1502 | (setq font-lock-defaults |
| 1492 | (cond | 1503 | (cond |
diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index 32ede0e1474..b119b03f0bf 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el | |||
| @@ -1858,7 +1858,8 @@ directory specification." | |||
| 1858 | (error "File %s not in current tags tables" file))))) | 1858 | (error "File %s not in current tags tables" file))))) |
| 1859 | (with-current-buffer "*Tags List*" | 1859 | (with-current-buffer "*Tags List*" |
| 1860 | (require 'apropos) | 1860 | (require 'apropos) |
| 1861 | (apropos-mode) | 1861 | (with-no-warnings |
| 1862 | (apropos-mode)) | ||
| 1862 | (setq buffer-read-only t))) | 1863 | (setq buffer-read-only t))) |
| 1863 | 1864 | ||
| 1864 | ;;;###autoload | 1865 | ;;;###autoload |
diff --git a/lisp/progmodes/flymake.el b/lisp/progmodes/flymake.el index 5463ee3ffa9..28a6aae2435 100644 --- a/lisp/progmodes/flymake.el +++ b/lisp/progmodes/flymake.el | |||
| @@ -47,7 +47,8 @@ | |||
| 47 | (defsubst flymake-makehash (&optional test) | 47 | (defsubst flymake-makehash (&optional test) |
| 48 | (if (fboundp 'make-hash-table) | 48 | (if (fboundp 'make-hash-table) |
| 49 | (if test (make-hash-table :test test) (make-hash-table)) | 49 | (if test (make-hash-table :test test) (make-hash-table)) |
| 50 | (makehash test))) | 50 | (with-no-warnings |
| 51 | (makehash test)))) | ||
| 51 | 52 | ||
| 52 | (defalias 'flymake-float-time | 53 | (defalias 'flymake-float-time |
| 53 | (if (fboundp 'float-time) | 54 | (if (fboundp 'float-time) |
diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index ba0266de574..1a26b64beca 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el | |||
| @@ -698,6 +698,7 @@ The key should be one of the cars in `gdb-buffer-rules-assoc'." | |||
| 698 | (define-key map "\C-c\C-z" 'gdb-inferior-io-stop) | 698 | (define-key map "\C-c\C-z" 'gdb-inferior-io-stop) |
| 699 | (define-key map "\C-c\C-\\" 'gdb-inferior-io-quit) | 699 | (define-key map "\C-c\C-\\" 'gdb-inferior-io-quit) |
| 700 | (define-key map "\C-c\C-d" 'gdb-inferior-io-eof) | 700 | (define-key map "\C-c\C-d" 'gdb-inferior-io-eof) |
| 701 | (define-key map "\C-d" 'gdb-inferior-io-eof) | ||
| 701 | map)) | 702 | map)) |
| 702 | 703 | ||
| 703 | (define-derived-mode gdb-inferior-io-mode comint-mode "Inferior I/O" | 704 | (define-derived-mode gdb-inferior-io-mode comint-mode "Inferior I/O" |
| @@ -953,7 +954,7 @@ function is used to change the focus of GUD tooltips to #define | |||
| 953 | directives." | 954 | directives." |
| 954 | (setq gdb-active-process nil) | 955 | (setq gdb-active-process nil) |
| 955 | (gdb-stopping ignored)) | 956 | (gdb-stopping ignored)) |
| 956 | 957 | ||
| 957 | (defun gdb-frame-begin (ignored) | 958 | (defun gdb-frame-begin (ignored) |
| 958 | (let ((sink gdb-output-sink)) | 959 | (let ((sink gdb-output-sink)) |
| 959 | (cond | 960 | (cond |
| @@ -1303,7 +1304,8 @@ static char *magick[] = { | |||
| 1303 | (looking-at "\\(\\S-+\\):\\([0-9]+\\)") | 1304 | (looking-at "\\(\\S-+\\):\\([0-9]+\\)") |
| 1304 | (let ((line (match-string 2)) (buffer-read-only nil) | 1305 | (let ((line (match-string 2)) (buffer-read-only nil) |
| 1305 | (file (match-string 1))) | 1306 | (file (match-string 1))) |
| 1306 | (add-text-properties (point-at-bol) (point-at-eol) | 1307 | (add-text-properties (line-beginning-position) |
| 1308 | (line-end-position) | ||
| 1307 | '(mouse-face highlight | 1309 | '(mouse-face highlight |
| 1308 | help-echo "mouse-2, RET: visit breakpoint")) | 1310 | help-echo "mouse-2, RET: visit breakpoint")) |
| 1309 | (unless (file-exists-p file) | 1311 | (unless (file-exists-p file) |
| @@ -1504,13 +1506,13 @@ static char *magick[] = { | |||
| 1504 | (let ((buffer-read-only nil)) | 1506 | (let ((buffer-read-only nil)) |
| 1505 | (goto-char (point-min)) | 1507 | (goto-char (point-min)) |
| 1506 | (while (< (point) (point-max)) | 1508 | (while (< (point) (point-max)) |
| 1507 | (add-text-properties (point-at-bol) (point-at-eol) | 1509 | (add-text-properties (line-beginning-position) (line-end-position) |
| 1508 | '(mouse-face highlight | 1510 | '(mouse-face highlight |
| 1509 | help-echo "mouse-2, RET: Select frame")) | 1511 | help-echo "mouse-2, RET: Select frame")) |
| 1510 | (beginning-of-line) | 1512 | (beginning-of-line) |
| 1511 | (when (and (looking-at "^#\\([0-9]+\\)") | 1513 | (when (and (looking-at "^#\\([0-9]+\\)") |
| 1512 | (equal (match-string 1) gdb-current-stack-level)) | 1514 | (equal (match-string 1) gdb-current-stack-level)) |
| 1513 | (put-text-property (point-at-bol) (point-at-eol) | 1515 | (put-text-property (line-beginning-position) (line-end-position) |
| 1514 | 'face '(:inverse-video t))) | 1516 | 'face '(:inverse-video t))) |
| 1515 | (forward-line 1)))))) | 1517 | (forward-line 1)))))) |
| 1516 | 1518 | ||
| @@ -1588,7 +1590,7 @@ static char *magick[] = { | |||
| 1588 | (let ((buffer-read-only nil)) | 1590 | (let ((buffer-read-only nil)) |
| 1589 | (goto-char (point-min)) | 1591 | (goto-char (point-min)) |
| 1590 | (while (< (point) (point-max)) | 1592 | (while (< (point) (point-max)) |
| 1591 | (add-text-properties (point-at-bol) (point-at-eol) | 1593 | (add-text-properties (line-beginning-position) (line-end-position) |
| 1592 | '(mouse-face highlight | 1594 | '(mouse-face highlight |
| 1593 | help-echo "mouse-2, RET: select thread")) | 1595 | help-echo "mouse-2, RET: select thread")) |
| 1594 | (forward-line 1))))) | 1596 | (forward-line 1))))) |
| @@ -1974,14 +1976,14 @@ corresponding to the mode line clicked." | |||
| 1974 | (let ((buf (gdb-get-buffer 'gdb-partial-output-buffer))) | 1976 | (let ((buf (gdb-get-buffer 'gdb-partial-output-buffer))) |
| 1975 | (with-current-buffer buf | 1977 | (with-current-buffer buf |
| 1976 | (goto-char (point-min)) | 1978 | (goto-char (point-min)) |
| 1977 | (while (re-search-forward "^ .*\n" nil t) | 1979 | (while (re-search-forward "^[ }].*\n" nil t) |
| 1978 | (replace-match "" nil nil)) | 1980 | (replace-match "" nil nil)) |
| 1979 | (goto-char (point-min)) | 1981 | (goto-char (point-min)) |
| 1980 | (while (re-search-forward "{[-0-9, {}\]*\n" nil t) | 1982 | (while (re-search-forward "{\\(.*=.*\n\\|\n\\)" nil t) |
| 1981 | (replace-match "(array);\n" nil nil)) | 1983 | (replace-match "(structure);\n" nil nil)) |
| 1982 | (goto-char (point-min)) | 1984 | (goto-char (point-min)) |
| 1983 | (while (re-search-forward "{.*=.*\n" nil t) | 1985 | (while (re-search-forward "\\s-*{.*\n" nil t) |
| 1984 | (replace-match "(structure);\n" nil nil)))) | 1986 | (replace-match " (array);\n" nil nil)))) |
| 1985 | (let ((buf (gdb-get-buffer 'gdb-locals-buffer))) | 1987 | (let ((buf (gdb-get-buffer 'gdb-locals-buffer))) |
| 1986 | (and buf (with-current-buffer buf | 1988 | (and buf (with-current-buffer buf |
| 1987 | (let ((p (point)) | 1989 | (let ((p (point)) |
| @@ -2316,8 +2318,8 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2316 | (delete-overlay overlay)))) | 2318 | (delete-overlay overlay)))) |
| 2317 | 2319 | ||
| 2318 | (defun gdb-put-breakpoint-icon (enabled bptno) | 2320 | (defun gdb-put-breakpoint-icon (enabled bptno) |
| 2319 | (let ((start (progn (beginning-of-line) (- (point) 1))) | 2321 | (let ((start (- (line-beginning-position) 1)) |
| 2320 | (end (progn (end-of-line) (+ (point) 1))) | 2322 | (end (+ (line-end-position) 1)) |
| 2321 | (putstring (if enabled "B" "b"))) | 2323 | (putstring (if enabled "B" "b"))) |
| 2322 | (add-text-properties | 2324 | (add-text-properties |
| 2323 | 0 1 '(help-echo "mouse-1: set/clear bkpt, mouse-3: enable/disable bkpt") | 2325 | 0 1 '(help-echo "mouse-1: set/clear bkpt, mouse-3: enable/disable bkpt") |
diff --git a/lisp/progmodes/idlwave.el b/lisp/progmodes/idlwave.el index 35e4b68c9b8..a118b0055a9 100644 --- a/lisp/progmodes/idlwave.el +++ b/lisp/progmodes/idlwave.el | |||
| @@ -3548,7 +3548,7 @@ is non-nil." | |||
| 3548 | (let ((pos (point))) | 3548 | (let ((pos (point))) |
| 3549 | (if idlwave-file-header | 3549 | (if idlwave-file-header |
| 3550 | (cond ((car idlwave-file-header) | 3550 | (cond ((car idlwave-file-header) |
| 3551 | (insert-file (car idlwave-file-header))) | 3551 | (insert-file-contents (car idlwave-file-header))) |
| 3552 | ((stringp (car (cdr idlwave-file-header))) | 3552 | ((stringp (car (cdr idlwave-file-header))) |
| 3553 | (insert (car (cdr idlwave-file-header)))))) | 3553 | (insert (car (cdr idlwave-file-header)))))) |
| 3554 | (goto-char pos))) | 3554 | (goto-char pos))) |
diff --git a/lisp/progmodes/make-mode.el b/lisp/progmodes/make-mode.el index 86002768757..05c3ac50787 100644 --- a/lisp/progmodes/make-mode.el +++ b/lisp/progmodes/make-mode.el | |||
| @@ -484,7 +484,7 @@ not be enclosed in { } or ( )." | |||
| 484 | ("\\\\\n" 0 "."))) | 484 | ("\\\\\n" 0 "."))) |
| 485 | 485 | ||
| 486 | (defvar makefile-imenu-generic-expression | 486 | (defvar makefile-imenu-generic-expression |
| 487 | `(("Dependencies" ,makefile-dependency-regex 1) | 487 | `(("Dependencies" makefile-previous-dependency 1) |
| 488 | ("Macro Assignment" ,makefile-macroassign-regex 1)) | 488 | ("Macro Assignment" ,makefile-macroassign-regex 1)) |
| 489 | "Imenu generic expression for Makefile mode. See `imenu-generic-expression'.") | 489 | "Imenu generic expression for Makefile mode. See `imenu-generic-expression'.") |
| 490 | 490 | ||
| @@ -854,7 +854,10 @@ Makefile mode can be configured by modifying the following variables: | |||
| 854 | "^\t[ \t]*\\(\\(?:\\(?:noecho\\|ignore[-_]error\\|[-@]+\\)[ \t]*\\)*\\)\\(\\(&\\S +\\)?\\(?:.+\\\\\n\\)*.+\\)") | 854 | "^\t[ \t]*\\(\\(?:\\(?:noecho\\|ignore[-_]error\\|[-@]+\\)[ \t]*\\)*\\)\\(\\(&\\S +\\)?\\(?:.+\\\\\n\\)*.+\\)") |
| 855 | 855 | ||
| 856 | (setq font-lock-defaults | 856 | (setq font-lock-defaults |
| 857 | `(makefile-makepp-font-lock-keywords ,@(cdr font-lock-defaults)))) | 857 | `(makefile-makepp-font-lock-keywords ,@(cdr font-lock-defaults)) |
| 858 | imenu-generic-expression | ||
| 859 | `(("Functions" "^[ \t]*\\(?:make\\)?sub[ \t]+\\([A-Za-z0-9_]+\\)" 1) | ||
| 860 | ,@imenu-generic-expression))) | ||
| 858 | 861 | ||
| 859 | ;;;###autoload | 862 | ;;;###autoload |
| 860 | (define-derived-mode makefile-bsdmake-mode makefile-mode "BSDmakefile" | 863 | (define-derived-mode makefile-bsdmake-mode makefile-mode "BSDmakefile" |
| @@ -866,10 +869,7 @@ Makefile mode can be configured by modifying the following variables: | |||
| 866 | (set (make-local-variable 'makefile-rule-action-regex) | 869 | (set (make-local-variable 'makefile-rule-action-regex) |
| 867 | "^\t[ \t]*\\([-+@]*\\)[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)") | 870 | "^\t[ \t]*\\([-+@]*\\)[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)") |
| 868 | (setq font-lock-defaults | 871 | (setq font-lock-defaults |
| 869 | `(makefile-bsdmake-font-lock-keywords ,@(cdr font-lock-defaults)) | 872 | `(makefile-bsdmake-font-lock-keywords ,@(cdr font-lock-defaults)))) |
| 870 | imenu-generic-expression | ||
| 871 | `(("Dependencies" ,makefile-dependency-regex 1) | ||
| 872 | ,@(cdr imenu-generic-expression)))) | ||
| 873 | 873 | ||
| 874 | 874 | ||
| 875 | 875 | ||
| @@ -1682,7 +1682,7 @@ matched in a rule action." | |||
| 1682 | (catch 'found | 1682 | (catch 'found |
| 1683 | (let ((pt (point))) | 1683 | (let ((pt (point))) |
| 1684 | (while (progn (skip-chars-forward makefile-dependency-skip bound) | 1684 | (while (progn (skip-chars-forward makefile-dependency-skip bound) |
| 1685 | (not (eobp))) | 1685 | (< (point) (or bound (point-max)))) |
| 1686 | (forward-char) | 1686 | (forward-char) |
| 1687 | (or (eq (char-after) ?=) | 1687 | (or (eq (char-after) ?=) |
| 1688 | (get-text-property (1- (point)) 'face) | 1688 | (get-text-property (1- (point)) 'face) |
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 0173c419b5d..87915933862 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el | |||
| @@ -1389,7 +1389,7 @@ with your script for an edit-interpret-debug cycle." | |||
| 1389 | (cond ((looking-at "#![ \t]?\\([^ \t\n]*/bin/env[ \t]\\)?\\([^ \t\n]+\\)") | 1389 | (cond ((looking-at "#![ \t]?\\([^ \t\n]*/bin/env[ \t]\\)?\\([^ \t\n]+\\)") |
| 1390 | (match-string 2)) | 1390 | (match-string 2)) |
| 1391 | ((and buffer-file-name | 1391 | ((and buffer-file-name |
| 1392 | (string-match "\\.m?spec$" buffer-file-name)) | 1392 | (string-match "\\.m?spec\\'" buffer-file-name)) |
| 1393 | "rpm"))))) | 1393 | "rpm"))))) |
| 1394 | (sh-set-shell (or interpreter sh-shell-file) nil nil)) | 1394 | (sh-set-shell (or interpreter sh-shell-file) nil nil)) |
| 1395 | (run-hooks 'sh-mode-hook)) | 1395 | (run-hooks 'sh-mode-hook)) |
| @@ -2290,7 +2290,7 @@ we go to the end of the previous line and do not check for continuations." | |||
| 2290 | (if (looking-at "[\"'`]") | 2290 | (if (looking-at "[\"'`]") |
| 2291 | (sh-safe-forward-sexp) | 2291 | (sh-safe-forward-sexp) |
| 2292 | ;; (> (skip-chars-forward "^ \t\n\"'`") 0) | 2292 | ;; (> (skip-chars-forward "^ \t\n\"'`") 0) |
| 2293 | (> (skip-chars-forward "-_a-zA-Z\$0-9") 0) | 2293 | (> (skip-chars-forward "-_a-zA-Z$0-9") 0) |
| 2294 | )) | 2294 | )) |
| 2295 | (buffer-substring start (point)) | 2295 | (buffer-substring start (point)) |
| 2296 | )) | 2296 | )) |
diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index 12f04895f98..f840ef356d9 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el | |||
| @@ -12364,8 +12364,8 @@ File statistics: \"%s\"\n\ | |||
| 12364 | (save-match-data | 12364 | (save-match-data |
| 12365 | (goto-char (match-end 1)) | 12365 | (goto-char (match-end 1)) |
| 12366 | ;; move to next item | 12366 | ;; move to next item |
| 12367 | (if (looking-at "\\(\\s-*,\\)") | 12367 | (if (looking-at "\\s-*,") |
| 12368 | (goto-char (match-end 1)) | 12368 | (goto-char (match-end 0)) |
| 12369 | (end-of-line) t)))) | 12369 | (end-of-line) t)))) |
| 12370 | (error t))) | 12370 | (error t))) |
| 12371 | 12371 | ||
| @@ -12736,7 +12736,7 @@ This does background highlighting of translate-off regions.") | |||
| 12736 | '(font-lock-syntactic-keywords . vhdl-font-lock-syntactic-keywords))) | 12736 | '(font-lock-syntactic-keywords . vhdl-font-lock-syntactic-keywords))) |
| 12737 | (when (fboundp 'font-lock-unset-defaults) | 12737 | (when (fboundp 'font-lock-unset-defaults) |
| 12738 | (font-lock-unset-defaults)) ; not implemented in XEmacs | 12738 | (font-lock-unset-defaults)) ; not implemented in XEmacs |
| 12739 | (font-lock-set-defaults) | 12739 | (font-lock-set-defaults) ;What for? --Stef |
| 12740 | (font-lock-mode nil) | 12740 | (font-lock-mode nil) |
| 12741 | (font-lock-mode t)) | 12741 | (font-lock-mode t)) |
| 12742 | 12742 | ||