diff options
Diffstat (limited to 'lisp/progmodes')
-rw-r--r-- | lisp/progmodes/cc-menus.el | 4 | ||||
-rw-r--r-- | lisp/progmodes/compile.el | 15 | ||||
-rw-r--r-- | lisp/progmodes/delphi.el | 2 |
3 files changed, 14 insertions, 7 deletions
diff --git a/lisp/progmodes/cc-menus.el b/lisp/progmodes/cc-menus.el index 95359689b9f..eced014d4e6 100644 --- a/lisp/progmodes/cc-menus.el +++ b/lisp/progmodes/cc-menus.el @@ -106,7 +106,9 @@ A sample value might look like: `\\(_P\\|_PROTO\\)'.") (nil ,(concat "^\\<" ; line MUST start with word char - "[^()]*" ; no parentheses before + ;; \n added to prevent overflow in regexp matcher. + ;; http://lists.gnu.org/archive/html/emacs-pretest-bug/2007-02/msg00021.html + "[^()\n]*" ; no parentheses before "[^" c-alnum "_:<>~]" ; match any non-identifier char "\\([" c-alpha "_][" c-alnum "_:<>~]*\\)" ; match function name "\\([ \t\n]\\|\\\\\n\\)*(" ; see above, BUT the arg list diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 9ed7ba09de9..482cfee1b9b 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -1658,10 +1658,15 @@ This is the value of `next-error-function' in Compilation buffers." ;; in the same process and buffer). ;; So, recalculate all markers for that file. (unless (and (nth 3 loc) (marker-buffer (nth 3 loc)) - (equal (nth 4 loc) - (setq timestamp - (with-current-buffer (marker-buffer (nth 3 loc)) - (visited-file-modtime))))) + ;; There may be no timestamp info if the loc is a `fake-loc'. + ;; So we skip the time-check here, although we should maybe + ;; change `compilation-fake-loc' to add timestamp info. + (or (null (nth 4 loc)) + (equal (nth 4 loc) + (setq timestamp + (with-current-buffer + (marker-buffer (nth 3 loc)) + (visited-file-modtime)))))) (with-current-buffer (compilation-find-file marker (caar (nth 2 loc)) (cadr (car (nth 2 loc)))) (save-restriction @@ -1711,7 +1716,7 @@ region and the first line of the next region." (or (consp file) (setq file (list file))) (setq file (compilation-get-file-structure file)) ;; Between the current call to compilation-fake-loc and the first occurrence - ;; of an error message referring to `file', the data is only kept is the + ;; of an error message referring to `file', the data is only kept in the ;; weak hash-table compilation-locs, so we need to prevent this entry ;; in compilation-locs from being GC'd away. --Stef (push file compilation-gcpro) diff --git a/lisp/progmodes/delphi.el b/lisp/progmodes/delphi.el index 6cbef6f426d..7c2417fde1a 100644 --- a/lisp/progmodes/delphi.el +++ b/lisp/progmodes/delphi.el @@ -1642,7 +1642,7 @@ before the indent, the point is moved to the indent." (when delphi-newline-always-indents ;; Indent both the (now) previous and current line first. (save-excursion - (previous-line 1) + (forward-line -1) (delphi-indent-line)) (delphi-indent-line))) |