emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] 08/31: Wrap `company-call-backend' in `condition-case'


From: Dmitry Gutov
Subject: [elpa] 08/31: Wrap `company-call-backend' in `condition-case'
Date: Tue, 18 Mar 2014 05:19:35 +0000

dgutov pushed a commit to branch master
in repository elpa.

commit b5a41ac931498556d481a29b7c7b3767b5d98367
Author: Dmitry Gutov <address@hidden>
Date:   Mon Feb 24 08:09:50 2014 +0200

    Wrap `company-call-backend' in `condition-case'
---
 company.el |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/company.el b/company.el
index a3bac0e..8482035 100644
--- a/company.el
+++ b/company.el
@@ -762,9 +762,12 @@ means that `company-mode' is always turned on except in 
`message-mode' buffers."
                 dir (file-name-directory (directory-file-name dir))))))))
 
 (defun company-call-backend (&rest args)
-  (if (functionp company-backend)
-      (apply company-backend args)
-    (apply 'company--multi-backend-adapter company-backend args)))
+  (condition-case err
+      (if (functionp company-backend)
+          (apply company-backend args)
+        (apply 'company--multi-backend-adapter company-backend args))
+    (error (error "Company: Back-end %s error \"%s\" with args %s"
+                    company-backend (error-message-string err) args))))
 
 (defun company--multi-backend-adapter (backends command &rest args)
   (let ((backends (loop for b in backends



reply via email to

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