branch: elpa/typescript-mode
commit 99c2b74ac38ef1bf0e66729ed7cace152bb14003
Author: Jostein Kjønigsen <[email protected]>
Commit: Jostein Kjønigsen <[email protected]>

    Make current-column function internal.
---
 typescript-mode-tests.el | 6 +++---
 typescript-mode.el       | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/typescript-mode-tests.el b/typescript-mode-tests.el
index c7fa26fceb..f1bd21be2a 100644
--- a/typescript-mode-tests.el
+++ b/typescript-mode-tests.el
@@ -104,15 +104,15 @@ a severity set to WARNING, no rule name."
 
   (with-temp-buffer
     (insert "大塚愛")
-    (should (equal 3 (typescript-current-column)))))
+    (should (equal 3 (typescript--current-column)))))
 
 (ert-deftest correctly-accounts-wide-chars-as-1-char-without-sideeffects ()
   "Otsuka Ai and other multi-char users should be a happy to write typescript."
 
   (with-temp-buffer
     (insert "大塚愛")
-    (let ((pos1 (typescript-current-column))
-          (pos2 (typescript-current-column)))
+    (let ((pos1 (typescript--current-column))
+          (pos2 (typescript--current-column)))
       (should (equal pos1 pos2)))))
 
 (provide 'typescript-mode-tests)
diff --git a/typescript-mode.el b/typescript-mode.el
index 07466125db..12840a00f1 100644
--- a/typescript-mode.el
+++ b/typescript-mode.el
@@ -1795,7 +1795,7 @@ nil."
            (+ typescript-indent-level typescript-expr-indent-offset))
           (t 0))))
 
-(defun typescript-current-column ()
+(defun typescript--current-column ()
   "Unicode aware version of `CURRENT-COLUMN' which correctly accounts for wide 
characters."
 
   (save-excursion
@@ -1810,7 +1810,7 @@ nil."
     (widen)
     (let* ((parse-status
             (save-excursion (syntax-ppss (point-at-bol))))
-           (offset (- (typescript-current-column) (current-indentation))))
+           (offset (- (typescript--current-column) (current-indentation))))
       (indent-line-to (typescript--proper-indentation parse-status))
       (when (> offset 0) (forward-char offset)))))
 

Reply via email to