auctex-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[AUCTeX-devel] [elpa] externals/auctex 836e461 03/69: Don't use TRIM arg


From: Tassilo Horn
Subject: [AUCTeX-devel] [elpa] externals/auctex 836e461 03/69: Don't use TRIM arg of split-string.
Date: Sat, 26 Mar 2016 21:36:31 +0000

branch: externals/auctex
commit 836e46136286941fbbb87178d33df9087469421e
Author: Tassilo Horn <address@hidden>
Commit: Tassilo Horn <address@hidden>

    Don't use TRIM arg of split-string.
    
    * tex-buf.el (TeX-parse-error): Don't use TRIM arg of
    `split-string' which is new in emacs 24.4.
---
 tex-buf.el |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/tex-buf.el b/tex-buf.el
index e64c3a2..8aaf14d 100644
--- a/tex-buf.el
+++ b/tex-buf.el
@@ -1540,12 +1540,15 @@ You might want to examine and modify the free variables 
`file',
         ((match-beginning 3)
          (let ((file (TeX-match-buffer 3))
                (end (match-end 3)))
-           ;; Trim, strip quotation marks and remove newlines if necessary
+           ;; Strip quotation marks and remove newlines if necessary
            (when (or (eq (string-to-char file) ?\")
                      (string-match "[  
]" file))
-             (setq file (mapconcat 'identity
-                                   (split-string file "[\"
]+" nil "[      ]")
-                                   "")))
+             (setq file (mapconcat 'identity (split-string file "[\"
]+") "")))
+           ;; Trim whitespace at the front/end
+           (setq file
+                 (progn
+                   (string-match 
"^[[:space:]]*\(.*[^[:space:]]\)[[:space:]]*$" file)
+                   (match-string 1 file)))
            (push file TeX-error-file)
            (push nil TeX-error-offset)
            (goto-char end))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]