diff options
author | Magnus Henoch <magnus.henoch@gmail.com> | 2015-08-13 16:59:16 -0400 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2015-08-13 16:59:16 -0400 |
commit | c24e742e00775a3e6964f32a521460345c9e07cb (patch) | |
tree | 5621053635771c2a57285eca2d0a20beb308a41e /lisp/progmodes | |
parent | 0319f122def8890266f7462bd55ec0bc31045d97 (diff) | |
download | emacs-c24e742e00775a3e6964f32a521460345c9e07cb.tar.gz |
* lisp/progmodes/compile.el: Assume 8-wide TABs (bug#21038)
* lisp/progmodes/compile.el: Use lexical-binding.
(compilation-move-to-column): Assume 8-wide TABs (bug#21038).
Diffstat (limited to 'lisp/progmodes')
-rw-r--r-- | lisp/progmodes/compile.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 9a4433595ef..9d1d14880e9 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -1,4 +1,4 @@ -;;; compile.el --- run compiler as inferior of Emacs, parse error messages +;;; compile.el --- run compiler as inferior of Emacs, parse error messages -*- lexical-binding:t -*- ;; Copyright (C) 1985-1987, 1993-1999, 2001-2015 Free Software ;; Foundation, Inc. @@ -1109,7 +1109,9 @@ If SCREEN is non-nil, columns are screen columns, otherwise, they are just char-counts." (setq col (- col compilation-first-column)) (if screen - (move-to-column (max col 0)) + ;; Presumably, the compilation tool doesn't know about our current + ;; `tab-width' setting, so it probably assumed 8-wide TABs (bug#21038). + (let ((tab-width 8)) (move-to-column (max col 0))) (goto-char (min (+ (line-beginning-position) col) (line-end-position))))) (defun compilation-internal-error-properties (file line end-line col end-col type fmts) |