File tree Expand file tree Collapse file tree 3 files changed +20
-22
lines changed Expand file tree Collapse file tree 3 files changed +20
-22
lines changed Original file line number Diff line number Diff line change @@ -1008,21 +1008,7 @@ export const scalaTmLanguage: TmLanguage = {
1008
1008
extension : {
1009
1009
patterns : [
1010
1010
{
1011
- match : `(extension)\\s+(?:(${ plainid } )\\s)?\\s*(on|(?=\\{))` ,
1012
- captures : {
1013
- '1' : {
1014
- name : 'keyword.declaration.scala'
1015
- } ,
1016
- '2' : {
1017
- name : 'entity.name.class'
1018
- } ,
1019
- '3' : {
1020
- name : 'keyword.declaration.scala'
1021
- }
1022
- }
1023
- } ,
1024
- {
1025
- match : `(extension)\\s+(?=[\\[\\(])` ,
1011
+ match : `^\\s*(extension)\\s+(?=[\\[\\(])` ,
1026
1012
captures : {
1027
1013
'1' : {
1028
1014
name : 'keyword.declaration.scala'
Original file line number Diff line number Diff line change
1
+ // SYNTAX TEST "source.scala"
2
+
3
+ val language = file.extension {
4
+ // ^^^^^^^^^ - keyword.declaration.scala
5
+ val language = file extension {
6
+ // ^^^^^^^^^ - keyword.declaration.scala
7
+ val language = file.extension(
8
+ // ^^^^^^^^^ - keyword.declaration.scala
9
+ val language = file extension (
10
+ // ^^^^^^^^^ - keyword.declaration.scala
Original file line number Diff line number Diff line change 1
1
// SYNTAX TEST "source.scala"
2
2
3
+ // Old syntax is not supported anymore. We make sure that it is not accidentally highlighted.
4
+
3
5
extension on (x : Rational ):
4
- // ^^^^^^^^^ keyword.declaration.scala
5
- // ^^ keyword.declaration.scala
6
+ // ^^^^^^^^^ - keyword.declaration.scala
7
+ // ^^ - keyword.declaration.scala
6
8
// ^ variable.parameter.scala
7
9
// ^^^^^^^^ entity.name.class
8
10
def > (y : Rational ): Boolean = y < x
9
11
10
12
extension Ops on (x : Rational ):
11
- // ^^^^^^^^^ keyword.declaration.scala
13
+ // ^^^^^^^^^ - keyword.declaration.scala
12
14
// ^^^ entity.name.class
13
- // ^^ keyword.declaration.scala
15
+ // ^^ - keyword.declaration.scala
14
16
// ^ variable.parameter.scala
15
17
// ^^^^^^^^ entity.name.class
16
18
def > (y : Rational ): Boolean = y < x
17
19
18
20
extension stringOps { }
19
- // ^^^^^^^^^ keyword.declaration.scala
20
- // ^^^^^^^^^ entity.name.class
21
+ // ^^^^^^^^^ - keyword.declaration.scala
22
+ // ^^^^^^^^^ - entity.name.class
21
23
22
24
extension { }
23
- // ^^^^^^^^^ keyword.declaration.scala
25
+ // ^^^^^^^^^ - keyword.declaration.scala
You can’t perform that action at this time.
0 commit comments