[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 33/35: Always include company-capf in the backends
From: |
Dmitry Gutov |
Subject: |
[elpa] 33/35: Always include company-capf in the backends |
Date: |
Sat, 19 Apr 2014 10:12:22 +0000 |
dgutov pushed a commit to branch master
in repository elpa.
commit 66d8567a78a9eb86a5fd549fbbb1d90faf692a17
Author: Dmitry Gutov <address@hidden>
Date: Sat Apr 19 05:02:37 2014 +0400
Always include company-capf in the backends
https://github.com/clojure-emacs/cider/issues/528#issuecomment-40800179
http://www.reddit.com/r/emacs/comments/22d7y6/autocomplete_or_companymode/cgma6qj
https://github.com/company-mode/company-mode/issues/95
---
NEWS.md | 2 ++
company-capf.el | 3 +--
company.el | 7 ++-----
3 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/NEWS.md b/NEWS.md
index 9037b01..bdb3de4 100644
--- a/NEWS.md
+++ b/NEWS.md
@@ -2,6 +2,8 @@
## Next
+* `company-capf` is included in `company-backends` in any supported Emacs
+ version (>= 24.1). `company-elisp` goes before it if Emacs version is < 24.4.
* New user option `company-clang-insert-arguments`, by default t.
* Default value of `company-idle-delay` lowered to `0.5`.
* New user option `company-tooltip-minimum-width`, by default 0.
diff --git a/company-capf.el b/company-capf.el
index 04f8413..3aaeb13 100644
--- a/company-capf.el
+++ b/company-capf.el
@@ -45,8 +45,7 @@
(when (and (consp (cdr data)) (numberp (nth 1 data))) data)))
(defun company-capf (command &optional arg &rest _args)
- "`company-mode' back-end using `completion-at-point-functions'.
-Requires Emacs 24.1 or newer."
+ "`company-mode' back-end using `completion-at-point-functions'."
(interactive (list 'interactive))
(pcase command
(`interactive (company-begin-backend 'company-capf))
diff --git a/company.el b/company.el
index 4440616..7fa5c2c 100644
--- a/company.el
+++ b/company.el
@@ -297,16 +297,13 @@ This doesn't include the margins and the scroll bar."
(assq backend company-safe-backends))
(cl-return t))))))
-(defvar company--include-capf (version< "24.3.50" emacs-version))
-
-(defcustom company-backends `(,@(unless company--include-capf
+(defcustom company-backends `(,@(unless (version< "24.3.50" emacs-version)
(list 'company-elisp))
company-bbdb
company-nxml company-css
company-eclim company-semantic company-clang
company-xcode company-ropemacs company-cmake
- ,@(when company--include-capf
- (list 'company-capf))
+ company-capf
(company-dabbrev-code company-gtags company-etags
company-keywords)
company-oddmuse company-files company-dabbrev)
- [elpa] 06/35: Drop Emacs 23 compatibility, (continued)
- [elpa] 06/35: Drop Emacs 23 compatibility, Dmitry Gutov, 2014/04/19
- [elpa] 11/35: Initial support for asynchonous backends (#62), Dmitry Gutov, 2014/04/19
- [elpa] 26/35: Merge pull request #100 from bbatsov/version-fix, Dmitry Gutov, 2014/04/19
- [elpa] 27/35: Try to use the more up-to-date snapshot packages, Dmitry Gutov, 2014/04/19
- [elpa] 29/35: Merge pull request #101 from bbatsov/master, Dmitry Gutov, 2014/04/19
- [elpa] 15/35: Merge branch 'clang-async', Dmitry Gutov, 2014/04/19
- [elpa] 30/35: Fix the test breakage (probably), Dmitry Gutov, 2014/04/19
- [elpa] 31/35: Introduce company-clang-insert-arguments, Dmitry Gutov, 2014/04/19
- [elpa] 05/35: Update NEWS, Dmitry Gutov, 2014/04/19
- [elpa] 34/35: Release 0.8.0, Dmitry Gutov, 2014/04/19
- [elpa] 33/35: Always include company-capf in the backends,
Dmitry Gutov <=
- [elpa] 35/35: Merge commit '51c140ca9ee32d27cacc7b2b07d4539bf98ae575' from company-master, Dmitry Gutov, 2014/04/19
- [elpa] 28/35: Use cl-lib, Dmitry Gutov, 2014/04/19
- [elpa] 32/35: `company-other-backend': don't use `company-manual-begin', Dmitry Gutov, 2014/04/19
- [elpa] 01/35: New option company-abort-manual-when-too-short, Dmitry Gutov, 2014/04/19