From 6bf24912a8a3c2cfc5e72073b8eb0f1137ab7728 Mon Sep 17 00:00:00 2001 From: Dmitry Gutov Date: Sun, 3 Jan 2016 00:21:32 +0200 Subject: [PATCH] Rename company-clang-obc-templatify to company-template-objc-templatify As requested in https://github.com/company-mode/company-mode/commit/5fc4a9a0b0c75f4f128ad01ca8befd1928399c86#commitcomment-15230965. --- NEWS.md | 2 ++ company-clang.el | 2 +- company-template.el | 2 +- test/template-tests.el | 6 +++--- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/NEWS.md b/NEWS.md index a32baded2..6fa729cf8 100644 --- a/NEWS.md +++ b/NEWS.md @@ -2,6 +2,8 @@ ## Next +* `company-clang-objc-templatify` has been renamed to + `company-template-objc-templatify`. * When duplicates are removed, completions without annotations are also removed in favor of completions with equal names that have annotations (experimental change) ([#432](https://github.com/company-mode/company-mode/issues/432)). diff --git a/company-clang.el b/company-clang.el index 890a25d84..067797f3f 100644 --- a/company-clang.el +++ b/company-clang.el @@ -323,7 +323,7 @@ passed via standard input." (when (and company-clang-insert-arguments anno) (insert anno) (if (string-match "\\`:[^:]" anno) - (company-clang-objc-templatify anno) + (company-template-objc-templatify anno) (company-template-c-like-templatify (concat arg anno)))))))) diff --git a/company-template.el b/company-template.el index 02065afaf..485faba6d 100644 --- a/company-template.el +++ b/company-template.el @@ -185,7 +185,7 @@ Leave point at the end of the field." ;; objc ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -(defun company-clang-objc-templatify (selector) +(defun company-template-objc-templatify (selector) (let* ((end (point-marker)) (beg (- (point) (length selector) 1)) (templ (company-template-declare-template beg end)) diff --git a/test/template-tests.el b/test/template-tests.el index 4db3ce3cb..da746bd72 100644 --- a/test/template-tests.el +++ b/test/template-tests.el @@ -105,15 +105,15 @@ (with-temp-buffer (let ((text "createBookWithTitle:andAuthor:")) (insert text) - (company-clang-objc-templatify text) + (company-template-objc-templatify text) (should (equal "createBookWithTitle:arg0 andAuthor:arg1" (buffer-string))) (should (looking-at "arg0")) (should (null (overlay-get (company-template-field-at) 'display)))))) -(ert-deftest company-clang-objc-templatify () +(ert-deftest company-template-objc-templatify () (with-temp-buffer (let ((text "createBookWithTitle:(NSString) andAuthor:(id)")) (insert text) - (company-clang-objc-templatify text) + (company-template-objc-templatify text) (should (equal (buffer-string) text)) (company-template-field-assert-text "(NSString)")))) -- 2.39.2