branch: elpa/kotlin-mode
commit a174f5ba4466909fcce9fe2a855f1108bc1c1af8
Author: Shodai Yokoyama <[email protected]>
Commit: Shodai Yokoyama <[email protected]>
kotlin-mode: Add kotlin-mode--match-interpolation
---
kotlin-mode.el | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/kotlin-mode.el b/kotlin-mode.el
index 6b9c2e982a..adab2d0ff4 100644
--- a/kotlin-mode.el
+++ b/kotlin-mode.el
@@ -213,6 +213,21 @@
start end))
)
+(defun kotlin-mode--match-interpolation (limit)
+ (let ((pos (next-single-char-property-change (point)
+ 'kotlin-property--interpolation
+ nil
+ limit)))
+ (when (and pos (> pos (point)))
+ (goto-char pos)
+ (let ((value (get-text-property pos 'kotlin-property--interpolation)))
+ (if value
+ (progn (set-match-data value)
+ t)
+ (kotlin-mode--match-interpolation limit)))))
+ )
+
+
(define-derived-mode kotlin-mode prog-mode "Kotlin"
"Major mode for editing Kotlin."