diff options
| author | Ivan Shmakov | 2015-05-27 22:15:27 +0000 |
|---|---|---|
| committer | Ivan Shmakov | 2015-05-27 22:15:27 +0000 |
| commit | 550c65011c7394e8ebcf91fc29af2984908279d1 (patch) | |
| tree | 09fea3decd7e8bf95026af54ce72609b7c49ffce /lisp | |
| parent | 21b81bd8c51cf48e08089087a17f66eb70625748 (diff) | |
| download | emacs-550c65011c7394e8ebcf91fc29af2984908279d1.tar.gz emacs-550c65011c7394e8ebcf91fc29af2984908279d1.zip | |
Avoid gratuitous delete-dups in face-at-point.
* lisp/faces.el (face-at-point): Do not compute the properly
ordered, duplicate-free list if only a single value is
requested anyway. (Bug#20519)
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/faces.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/faces.el b/lisp/faces.el index 9c087c99d56..f6b11074af0 100644 --- a/lisp/faces.el +++ b/lisp/faces.el | |||
| @@ -1937,8 +1937,9 @@ Return nil if there is no face." | |||
| 1937 | (dolist (face faceprop) | 1937 | (dolist (face faceprop) |
| 1938 | (if (facep face) | 1938 | (if (facep face) |
| 1939 | (push face faces)))))) | 1939 | (push face faces)))))) |
| 1940 | (setq faces (delete-dups (nreverse faces))) | 1940 | (if multiple |
| 1941 | (if multiple faces (car faces)))) | 1941 | (delete-dups (nreverse faces)) |
| 1942 | (car (last faces))))) | ||
| 1942 | 1943 | ||
| 1943 | (defun foreground-color-at-point () | 1944 | (defun foreground-color-at-point () |
| 1944 | "Return the foreground color of the character after point." | 1945 | "Return the foreground color of the character after point." |