[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/kotlin-mode eb2af1723e 07/10: Support value modifier
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/kotlin-mode eb2af1723e 07/10: Support value modifier |
Date: |
Tue, 17 Jan 2023 15:08:09 -0500 (EST) |
branch: elpa/kotlin-mode
commit eb2af1723e23813a09d07a59f51ded293994f8a0
Author: taku0 <mxxouy6x3m_github@tatapa.org>
Commit: taku0 <mxxouy6x3m_github@tatapa.org>
Support value modifier
---
kotlin-mode-lexer.el | 7 ++++---
test/pathological.kt | 7 +++++++
2 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/kotlin-mode-lexer.el b/kotlin-mode-lexer.el
index cf37034d84..0402325443 100644
--- a/kotlin-mode-lexer.el
+++ b/kotlin-mode-lexer.el
@@ -578,7 +578,7 @@ expression as a token with one of the following types:
'("vararg" "crossinline" "noinline"))
(defconst kotlin-mode--function-modifier-keywords
- '("tailrec" "operator" "infix" "inline" "external" "suspend"))
+ '("tailrec" "operator" "infix" "inline" "value" "external" "suspend"))
(defconst kotlin-mode--modifier-keywords
(append kotlin-mode--inheritance-modifier-keywords
@@ -644,8 +644,9 @@ expression as a token with one of the following types:
;; Labels
(eq (kotlin-mode--token-type previous-token) 'label)
;; Modifiers
- (member (kotlin-mode--token-text previous-token)
- kotlin-mode--modifier-keywords))
+ (and (member (kotlin-mode--token-text previous-token)
+ kotlin-mode--modifier-keywords)
+ (not (equal (kotlin-mode--token-text previous-token) "value"))))
nil)
;; Tokens that cannot end a statement
diff --git a/test/pathological.kt b/test/pathological.kt
index 09e7c41801..c12342fe66 100644
--- a/test/pathological.kt
+++ b/test/pathological.kt
@@ -425,8 +425,15 @@ public
)
->
C
+
+ // value class
+
+ value
+ class Foo { // KNOWN_BUG
+ } // KNOWN_BUG
}
+
// statements
fun foo() {
//explicit semicolons
- [nongnu] elpa/kotlin-mode updated (ff4637c4ea -> 3a84689d0b), ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode e8969a6214 02/10: Move lexical level routines to kotlin-mode-lexer.el, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode 0a41f8b7fd 03/10: Fix ckeckdoc errors, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode 115a7dd7e3 04/10: Rewrite indentation logic, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode 23a693d264 05/10: Add documentation of indentation logic, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode 1854330e27 06/10: Fix for 24.x when template string is incomplete, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode c7d5c67ebc 01/10: Improve detection of line continuation, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode 2f64645460 08/10: Support definitely non-nullable type, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode eb2af1723e 07/10: Support value modifier,
ELPA Syncer <=
- [nongnu] elpa/kotlin-mode 70de2560a6 09/10: Support closed range operator, ELPA Syncer, 2023/01/17
- [nongnu] elpa/kotlin-mode 3a84689d0b 10/10: Merge pull request #53 from taku0/rewite-indentation, ELPA Syncer, 2023/01/17