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

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

[elpa] 04/52: company-clang: tweak the objc args recognition


From: Dmitry Gutov
Subject: [elpa] 04/52: company-clang: tweak the objc args recognition
Date: Tue, 01 Jul 2014 11:53:04 +0000

dgutov pushed a commit to branch master
in repository elpa.

commit ee3e77d86246b5a46f76a810bd10e9e78f385721
Author: Dmitry Gutov <address@hidden>
Date:   Tue Apr 29 12:21:49 2014 +0400

    company-clang: tweak the objc args recognition
---
 company-clang.el |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/company-clang.el b/company-clang.el
index 1ddb7ca..a53a296 100644
--- a/company-clang.el
+++ b/company-clang.el
@@ -146,7 +146,7 @@ or automatically through a custom 
`company-clang-prefix-guesser'."
     (cond
      ((null meta) nil)
      ((string-match "[^:]:[^:]" meta)
-      (substring meta (match-beginning 0)))
+      (substring meta (1+ (match-beginning 0))))
      ((string-match "\\((.*)\\'\\)" meta)
       (match-string 1 meta)))))
 
@@ -316,7 +316,7 @@ passed via standard input."
     (post-completion (let ((anno (company-clang--annotation arg)))
                        (when (and company-clang-insert-arguments anno)
                          (insert anno)
-                         (if (string-match "[^:]:[^:]" anno)
+                         (if (string-match "\\`:[^:]" anno)
                              (company-clang-objc-templatify anno)
                            (company-template-c-like-templatify anno)))))))
 



reply via email to

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