Skip to content

Commit f2a9eeb

Browse files
AlexanderPrendotamarijnh
authored andcommitted
[clike] Support @-identifiers in Kotlin mode
1 parent 419aa76 commit f2a9eeb

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

mode/clike/clike.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -624,6 +624,10 @@ CodeMirror.defineMode("clike", function(config, parserConfig) {
624624
defKeywords: words("class val var object interface fun"),
625625
atoms: words("true false null this"),
626626
hooks: {
627+
"@": function(stream) {
628+
stream.eatWhile(/[\w\$_]/);
629+
return "meta";
630+
},
627631
'"': function(stream, state) {
628632
state.tokenize = tokenKotlinString(stream.match('""'));
629633
return state.tokenize(stream, state);

0 commit comments

Comments
 (0)