summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorGeorge Fraser <george@fivetran.com>2018-10-12 10:10:39 -0700
committerGeorge Fraser <george@fivetran.com>2018-10-12 10:10:39 -0700
commit7f6dc4b4206be1613d3c89d9efc78e8e5fca25a5 (patch)
tree991a73089588bdac5f9d4d162a3413093346769a /lib
parent8844568c090be70a2e9346e698fce57ce3ffcc10 (diff)
downloadjava-language-server-7f6dc4b4206be1613d3c89d9efc78e8e5fca25a5.zip
Reorganize
Diffstat (limited to 'lib')
-rw-r--r--lib/java.tmLanguage.json88
1 files changed, 51 insertions, 37 deletions
diff --git a/lib/java.tmLanguage.json b/lib/java.tmLanguage.json
index 16d3d4a..5ca0a3c 100644
--- a/lib/java.tmLanguage.json
+++ b/lib/java.tmLanguage.json
@@ -47,47 +47,16 @@
"include": "#keywords"
},
{
- "match": "\\b(private|public|protected|static|final|default)\\b",
- "name": "storage.modifier.java"
+ "include": "#modifiers"
},
{
- "match": "\\b(instanceof)\\s+((\\w+\\.)*\\w+)",
- "captures": {
- "1": {
- "name": "keyword.instanceof.java"
- },
- "2": {
- "name": "entity.name.class.java"
- }
- },
- "name": "meta.instanceof.java"
- },
- {
- "begin": "\\b(new)\\s+((\\w+\\.)*\\w+)",
- "beginCaptures": {
- "1": {
- "name": "keyword.new.java"
- },
- "2": {
- "name": "entity.name.class.java"
- }
- },
- "end": "\\(",
- "name": "meta.new.java",
- "patterns": [
- {
- "include": "#keywords"
- },
- {
- "include": "#class-name"
- }
- ]
+ "include": "#comments"
},
{
"include": "#constants"
},
{
- "include": "#comments"
+ "include": "#builtins"
}
],
"repository": {
@@ -99,11 +68,11 @@
}
]
},
- "class-name": {
+ "modifiers": {
"patterns": [
{
- "match": "(\\w+\\.)*\\w+",
- "name": "entity.name.class.java"
+ "match": "\\b(private|public|protected|static|final|default)\\b",
+ "name": "storage.modifier.java"
}
]
},
@@ -204,6 +173,51 @@
]
}
]
+ },
+ "builtins": {
+ "patterns": [
+ {
+ "match": "\\b(instanceof)\\s+((\\w+\\.)*\\w+)",
+ "captures": {
+ "1": {
+ "name": "keyword.instanceof.java"
+ },
+ "2": {
+ "name": "entity.name.class.java"
+ }
+ },
+ "name": "meta.instanceof.java"
+ },
+ {
+ "begin": "\\b(new)\\s+((\\w+\\.)*\\w+)",
+ "beginCaptures": {
+ "1": {
+ "name": "keyword.new.java"
+ },
+ "2": {
+ "name": "entity.name.class.java"
+ }
+ },
+ "end": "\\(",
+ "name": "meta.new.java",
+ "patterns": [
+ {
+ "include": "#keywords"
+ },
+ {
+ "include": "#class-name"
+ }
+ ]
+ }
+ ]
+ },
+ "class-name": {
+ "patterns": [
+ {
+ "match": "(\\w+\\.)*\\w+",
+ "name": "entity.name.class.java"
+ }
+ ]
}
}
} \ No newline at end of file