[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master b1127da 16/29: Don't show (anonymous) as function annotati
From: |
Dmitry Gutov |
Subject: |
[elpa] master b1127da 16/29: Don't show (anonymous) as function annotation, or in argument expansions |
Date: |
Tue, 28 Mar 2017 20:50:35 -0400 (EDT) |
branch: master
commit b1127da1cbb6e4f0a43a5a9223b5fec515e30818
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>
Don't show (anonymous) as function annotation, or in argument expansions
Fixes #628
---
company-clang.el | 1 +
test/clang-tests.el | 6 ++++++
2 files changed, 7 insertions(+)
diff --git a/company-clang.el b/company-clang.el
index 1cb24c9..599491d 100644
--- a/company-clang.el
+++ b/company-clang.el
@@ -161,6 +161,7 @@ or automatically through a custom
`company-clang-prefix-guesser'."
((null meta) nil)
((string-match "[^:]:[^:]" meta)
(substring meta (1+ (match-beginning 0))))
+ ((string-match "(anonymous)" meta) nil)
((string-match "\\((.*)[ a-z]*\\'\\)" meta)
(let ((paren (match-beginning 1)))
(if (not (eq (aref meta (1- paren)) ?>))
diff --git a/test/clang-tests.el b/test/clang-tests.el
index 2b8b105..86f7382 100644
--- a/test/clang-tests.el
+++ b/test/clang-tests.el
@@ -43,3 +43,9 @@
(ert-deftest company-clang-null-annotation ()
(let ((str "char"))
(should (null (company-clang 'annotation str)))))
+
+(ert-deftest company-clang-anon-union-annotation ()
+ (let ((u (propertize "u" 'meta "union (anonymous) u"))
+ (s (propertize "s" 'meta "struct (anonymous) s")))
+ (should (null (company-clang 'annotation u)))
+ (should (null (company-clang 'annotation s)))))
- [elpa] master updated (4f12749 -> edc5d03), Dmitry Gutov, 2017/03/28
- [elpa] master ec7a860 03/29: Merge pull request #616 from terlar/add-enh-ruby-mode-keyword-alias, Dmitry Gutov, 2017/03/28
- [elpa] master 0499c02 02/29: company-keywords-alist: add enh-ruby-mode -> ruby-mode alias, Dmitry Gutov, 2017/03/28
- [elpa] master 92b0bf7 06/29: Use pipes instead of PTYs to receive output from Clang, Dmitry Gutov, 2017/03/28
- [elpa] master 6f2ae7f 09/29: Merge pull request #621 from juergenhoetzel/use-pipes, Dmitry Gutov, 2017/03/28
- [elpa] master 21357f6 11/29: Update NEWS, Dmitry Gutov, 2017/03/28
- [elpa] master bc2ce4e 18/29: Support Tramp in company-gtags, Dmitry Gutov, 2017/03/28
- [elpa] master b1127da 16/29: Don't show (anonymous) as function annotation, or in argument expansions,
Dmitry Gutov <=
- [elpa] master 31063e1 20/29: Fix company-auto-complete and electric-pair-mode compatibility, Dmitry Gutov, 2017/03/28
- [elpa] master cf98238 04/29: Preview the common part of completion candidates, Dmitry Gutov, 2017/03/28
- [elpa] master 40e2200 07/29: Preview func take the exact common part, Dmitry Gutov, 2017/03/28
- [elpa] master a2ec806 12/29: Use tramp-aware `start-file-process' to start completion process, Dmitry Gutov, 2017/03/28
- [elpa] master a4d0421 05/29: Modified for the original frontends to work, Dmitry Gutov, 2017/03/28
- [elpa] master 1c516df 01/29: Increase the minimum Emacs version dependency, Dmitry Gutov, 2017/03/28
- [elpa] master c494fc6 17/29: Fix a failing test, Dmitry Gutov, 2017/03/28
- [elpa] master ec12e27 27/29: Merge branch 'master' of github.com:company-mode/company-mode, Dmitry Gutov, 2017/03/28
- [elpa] master f149940 28/29: Release 0.9.3, Dmitry Gutov, 2017/03/28
- [elpa] master ce42fcf 23/29: Update copyright years, Dmitry Gutov, 2017/03/28