diff options
| author | Glenn Morris | 2020-02-20 07:50:30 -0800 |
|---|---|---|
| committer | Glenn Morris | 2020-02-20 07:50:30 -0800 |
| commit | 398afbaf6f31d89b5cb813b75a28b98cf7b1acd2 (patch) | |
| tree | 587f23019db4d4b1a5b138c741dd2895483cbca8 /lisp | |
| parent | 770f76f050376bbd77a3cc8cf44db57cf855a27c (diff) | |
| parent | 9f0852474810311fd2b26fa3756ab6d816016389 (diff) | |
| download | emacs-398afbaf6f31d89b5cb813b75a28b98cf7b1acd2.tar.gz emacs-398afbaf6f31d89b5cb813b75a28b98cf7b1acd2.zip | |
Merge from origin/emacs-27
9f08524748 (origin/emacs-27) Fix broken regexps
1d10885763 ; spelling and comment fix
614203bc80 ; make change-history-commit
28399e585e * Makefile.in (PREFERRED_BRANCH): Now emacs-27.
62afbc513a Fix bug when visiting euc-jp-encoded directories
a2c4eeeecd Clarify when fixnums are used.
4e5ac4b0c6 Reorder discussion of integer basics
f765aad28b Make OMake support slightly less expensive (bug#39595)
39410cfc5a Speed up 'msft' and 'watcom' compilation error regexps
96a269d045 Speed up 'maven' compilation error message regexp
efc9d4fe3e Amend c-backward-sws better to handle multiline block comm...
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/progmodes/cc-defs.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/cc-engine.el | 35 | ||||
| -rw-r--r-- | lisp/progmodes/compile.el | 30 | ||||
| -rw-r--r-- | lisp/progmodes/simula.el | 2 |
4 files changed, 50 insertions, 19 deletions
diff --git a/lisp/progmodes/cc-defs.el b/lisp/progmodes/cc-defs.el index 5ca64a0a752..12be09d9b45 100644 --- a/lisp/progmodes/cc-defs.el +++ b/lisp/progmodes/cc-defs.el | |||
| @@ -1278,7 +1278,7 @@ point is then left undefined." | |||
| 1278 | place ,property nil ,(or limit '(point-min))))) | 1278 | place ,property nil ,(or limit '(point-min))))) |
| 1279 | (when (> place ,(or limit '(point-min))) | 1279 | (when (> place ,(or limit '(point-min))) |
| 1280 | (goto-char place) | 1280 | (goto-char place) |
| 1281 | (search-backward-regexp "\\(n\\|.\\)") ; to set the match-data. | 1281 | (search-backward-regexp "\\(\n\\|.\\)") ; to set the match-data. |
| 1282 | (point)))) | 1282 | (point)))) |
| 1283 | 1283 | ||
| 1284 | (defun c-clear-char-property-with-value-function (from to property value) | 1284 | (defun c-clear-char-property-with-value-function (from to property value) |
diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 0964c04b899..0c338fa3868 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el | |||
| @@ -327,6 +327,8 @@ comment at the start of cc-engine.el for more info." | |||
| 327 | (when (or (null lim) | 327 | (when (or (null lim) |
| 328 | (>= here lim)) | 328 | (>= here lim)) |
| 329 | (save-match-data | 329 | (save-match-data |
| 330 | ;; Note the similarity of the code here to some in | ||
| 331 | ;; `c-backward-sws'. | ||
| 330 | (while | 332 | (while |
| 331 | (progn | 333 | (progn |
| 332 | (while (eq (char-before (1- (point))) ?\\) | 334 | (while (eq (char-before (1- (point))) ?\\) |
| @@ -2461,17 +2463,34 @@ comment at the start of cc-engine.el for more info." | |||
| 2461 | (/= cmt-skip-pos simple-ws-beg) | 2463 | (/= cmt-skip-pos simple-ws-beg) |
| 2462 | (c-beginning-of-macro)) | 2464 | (c-beginning-of-macro)) |
| 2463 | ;; Inside a cpp directive. See if it should be skipped over. | 2465 | ;; Inside a cpp directive. See if it should be skipped over. |
| 2464 | (let ((cpp-beg (point))) | 2466 | (let ((cpp-beg (point)) |
| 2467 | pause pos) | ||
| 2465 | 2468 | ||
| 2466 | ;; Move back over all line continuations in the region skipped | 2469 | ;; Move back over all line continuations and block comments in |
| 2467 | ;; over by `c-backward-comments'. If we go past it then we | 2470 | ;; the region skipped over by `c-backward-comments'. If we go |
| 2468 | ;; started inside the cpp directive. | 2471 | ;; past it then we started inside the cpp directive. |
| 2469 | (goto-char simple-ws-beg) | 2472 | (goto-char simple-ws-beg) |
| 2470 | (beginning-of-line) | 2473 | (beginning-of-line) |
| 2471 | (while (and (> (point) cmt-skip-pos) | 2474 | ;; Note the similarity of the code here to some in |
| 2472 | (progn (backward-char) | 2475 | ;; `c-beginning-of-macro'. |
| 2473 | (eq (char-before) ?\\))) | 2476 | (setq pause (point)) |
| 2474 | (beginning-of-line)) | 2477 | (while |
| 2478 | (progn | ||
| 2479 | (while (and (> (point) cmt-skip-pos) | ||
| 2480 | (progn (backward-char) | ||
| 2481 | (eq (char-before) ?\\))) | ||
| 2482 | (beginning-of-line)) | ||
| 2483 | (setq pos (point)) | ||
| 2484 | (when (and c-last-c-comment-end-on-line-re | ||
| 2485 | (re-search-forward | ||
| 2486 | c-last-c-comment-end-on-line-re pause t)) | ||
| 2487 | (goto-char (match-end 1)) | ||
| 2488 | (if (c-backward-single-comment) | ||
| 2489 | (progn | ||
| 2490 | (beginning-of-line) | ||
| 2491 | (setq pause (point))) | ||
| 2492 | (goto-char pos) | ||
| 2493 | nil)))) | ||
| 2475 | 2494 | ||
| 2476 | (if (< (point) cmt-skip-pos) | 2495 | (if (< (point) cmt-skip-pos) |
| 2477 | ;; Don't move past the cpp directive if we began inside | 2496 | ;; Don't move past the cpp directive if we began inside |
diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 48ac85a73b7..455f181f501 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el | |||
| @@ -221,7 +221,7 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) | |||
| 221 | ;; considered before EDG. | 221 | ;; considered before EDG. |
| 222 | ;; The message may be a "warning", "error", or "fatal error" with | 222 | ;; The message may be a "warning", "error", or "fatal error" with |
| 223 | ;; an error code, or "see declaration of" without an error code. | 223 | ;; an error code, or "see declaration of" without an error code. |
| 224 | "^ *\\([0-9]+>\\)?\\(\\(?:[a-zA-Z]:\\)?[^:(\t\n]+\\)(\\([0-9]+\\)) ?\ | 224 | "^ *\\([0-9]+>\\)?\\(\\(?:[a-zA-Z]:\\)?[^ :(\t\n][^:(\t\n]*\\)(\\([0-9]+\\)) ?\ |
| 225 | : \\(?:see declaration\\|\\(?:warnin\\(g\\)\\|[a-z ]+\\) C[0-9]+:\\)" | 225 | : \\(?:see declaration\\|\\(?:warnin\\(g\\)\\|[a-z ]+\\) C[0-9]+:\\)" |
| 226 | 2 3 nil (4)) | 226 | 2 3 nil (4)) |
| 227 | 227 | ||
| @@ -268,12 +268,24 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) | |||
| 268 | (jikes-file | 268 | (jikes-file |
| 269 | "^\\(?:Found\\|Issued\\) .* compiling \"\\(.+\\)\":$" 1 nil nil 0) | 269 | "^\\(?:Found\\|Issued\\) .* compiling \"\\(.+\\)\":$" 1 nil nil 0) |
| 270 | 270 | ||
| 271 | |||
| 272 | ;; This used to be pathologically slow on long lines (Bug#3441), | ||
| 273 | ;; due to matching filenames via \\(.*?\\). This might be faster. | ||
| 274 | (maven | 271 | (maven |
| 275 | ;; Maven is a popular free software build tool for Java. | 272 | ;; Maven is a popular free software build tool for Java. |
| 276 | "\\(\\[WARNING\\] *\\)?\\([^ \n]\\(?:[^\n :]\\| [^-/\n]\\|:[^ \n]\\)*?\\):\\[\\([0-9]+\\),\\([0-9]+\\)\\] " 2 3 4 (1)) | 273 | ,(rx bol |
| 274 | ;; It is unclear whether the initial [type] tag is always present. | ||
| 275 | (? "[" | ||
| 276 | (or "ERROR" (group-n 1 "WARNING") (group-n 2 "INFO")) | ||
| 277 | "] ") | ||
| 278 | (group-n 3 ; File | ||
| 279 | (not (any "\n [")) | ||
| 280 | (* (or (not (any "\n :")) | ||
| 281 | (: " " (not (any "\n/-"))) | ||
| 282 | (: ":" (not (any "\n [")))))) | ||
| 283 | ":[" | ||
| 284 | (group-n 4 (+ digit)) ; Line | ||
| 285 | "," | ||
| 286 | (group-n 5 (+ digit)) ; Column | ||
| 287 | "] ") | ||
| 288 | 3 4 5 (1 . 2)) | ||
| 277 | 289 | ||
| 278 | (jikes-line | 290 | (jikes-line |
| 279 | "^ *\\([0-9]+\\)\\.[ \t]+.*\n +\\(<-*>\n\\*\\*\\* \\(?:Error\\|Warnin\\(g\\)\\)\\)" | 291 | "^ *\\([0-9]+\\)\\.[ \t]+.*\n +\\(<-*>\n\\*\\*\\* \\(?:Error\\|Warnin\\(g\\)\\)\\)" |
| @@ -294,7 +306,7 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) | |||
| 294 | 1 2 3 (4 . 5)) | 306 | 1 2 3 (4 . 5)) |
| 295 | 307 | ||
| 296 | (ruby-Test::Unit | 308 | (ruby-Test::Unit |
| 297 | "^[\t ]*\\[\\([^(].*\\):\\([1-9][0-9]*\\)\\(\\]\\)?:in " 1 2) | 309 | "^ [[ ]?\\([^ (].*\\):\\([1-9][0-9]*\\)\\(\\]\\)?:in " 1 2) |
| 298 | 310 | ||
| 299 | (gmake | 311 | (gmake |
| 300 | ;; Set GNU make error messages as INFO level. | 312 | ;; Set GNU make error messages as INFO level. |
| @@ -394,7 +406,7 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) | |||
| 394 | (omake | 406 | (omake |
| 395 | ;; "omake -P" reports "file foo changed" | 407 | ;; "omake -P" reports "file foo changed" |
| 396 | ;; (useful if you do "cvs up" and want to see what has changed) | 408 | ;; (useful if you do "cvs up" and want to see what has changed) |
| 397 | "omake: file \\(.*\\) changed" 1 nil nil nil nil | 409 | "^\\*\\*\\* omake: file \\(.*\\) changed" 1 nil nil nil nil |
| 398 | ;; FIXME-omake: This tries to prevent reusing pre-existing markers | 410 | ;; FIXME-omake: This tries to prevent reusing pre-existing markers |
| 399 | ;; for subsequent messages, since those messages's line numbers | 411 | ;; for subsequent messages, since those messages's line numbers |
| 400 | ;; are about another version of the file. | 412 | ;; are about another version of the file. |
| @@ -443,7 +455,7 @@ File = \\(.+\\), Line = \\([0-9]+\\)\\(?:, Column = \\([0-9]+\\)\\)?" | |||
| 443 | "^\\([^, \n\t]+\\), line \\([0-9]+\\), char \\([0-9]+\\)[:., (-]" 1 2 3) | 455 | "^\\([^, \n\t]+\\), line \\([0-9]+\\), char \\([0-9]+\\)[:., (-]" 1 2 3) |
| 444 | 456 | ||
| 445 | (watcom | 457 | (watcom |
| 446 | "^[ \t]*\\(\\(?:[a-zA-Z]:\\)?[^:(\t\n]+\\)(\\([0-9]+\\)): ?\ | 458 | "^[ \t]*\\(\\(?:[a-zA-Z]:\\)?[^ :(\t\n][^:(\t\n]*\\)(\\([0-9]+\\)): ?\ |
| 447 | \\(?:\\(Error! E[0-9]+\\)\\|\\(Warning! W[0-9]+\\)\\):" | 459 | \\(?:\\(Error! E[0-9]+\\)\\|\\(Warning! W[0-9]+\\)\\):" |
| 448 | 1 2 nil (4)) | 460 | 1 2 nil (4)) |
| 449 | 461 | ||
| @@ -1441,7 +1453,7 @@ to `compilation-error-regexp-alist' if RULES is nil." | |||
| 1441 | ((not (memq 'omake compilation-error-regexp-alist)) nil) | 1453 | ((not (memq 'omake compilation-error-regexp-alist)) nil) |
| 1442 | ((string-match "\\`\\([^^]\\|\\^\\( \\*\\|\\[\\)\\)" pat) | 1454 | ((string-match "\\`\\([^^]\\|\\^\\( \\*\\|\\[\\)\\)" pat) |
| 1443 | nil) ;; Not anchored or anchored but already allows empty spaces. | 1455 | nil) ;; Not anchored or anchored but already allows empty spaces. |
| 1444 | (t (setq pat (concat "^ *" (substring pat 1))))) | 1456 | (t (setq pat (concat "^\\(?: \\)?" (substring pat 1))))) |
| 1445 | 1457 | ||
| 1446 | (if (consp file) (setq fmt (cdr file) file (car file))) | 1458 | (if (consp file) (setq fmt (cdr file) file (car file))) |
| 1447 | (if (consp line) (setq end-line (cdr line) line (car line))) | 1459 | (if (consp line) (setq end-line (cdr line) line (car line))) |
diff --git a/lisp/progmodes/simula.el b/lisp/progmodes/simula.el index 5d5f180a5cf..be3edfdc6e4 100644 --- a/lisp/progmodes/simula.el +++ b/lisp/progmodes/simula.el | |||
| @@ -367,7 +367,7 @@ Turning on SIMULA mode calls the value of the variable simula-mode-hook | |||
| 367 | with no arguments, if that value is non-nil." | 367 | with no arguments, if that value is non-nil." |
| 368 | (set (make-local-variable 'comment-column) 40) | 368 | (set (make-local-variable 'comment-column) 40) |
| 369 | ;; (set (make-local-variable 'end-comment-column) 75) | 369 | ;; (set (make-local-variable 'end-comment-column) 75) |
| 370 | (set (make-local-variable 'paragraph-start) "[ \t]*$\\|\\f") | 370 | (set (make-local-variable 'paragraph-start) "[ \t]*$\\|\f") |
| 371 | (set (make-local-variable 'paragraph-separate) paragraph-start) | 371 | (set (make-local-variable 'paragraph-separate) paragraph-start) |
| 372 | (set (make-local-variable 'indent-line-function) 'simula-indent-line) | 372 | (set (make-local-variable 'indent-line-function) 'simula-indent-line) |
| 373 | (set (make-local-variable 'comment-start) "! ") | 373 | (set (make-local-variable 'comment-start) "! ") |