diff options
| author | Bruno BELANYI <bruno@belanyi.fr> | 2022-06-14 20:01:12 +0200 |
|---|---|---|
| committer | Stephan Seitz <stephan.seitz@fau.de> | 2022-06-14 22:34:03 +0200 |
| commit | b8e3b03748e0c796648360417650302a826ada91 (patch) | |
| tree | 1a6600bcf44037995c25c780cdac8911c45aef96 /tests/query/highlights | |
| parent | test(tiger): import upstream tests (diff) | |
| download | nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.tar nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.tar.gz nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.tar.bz2 nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.tar.lz nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.tar.xz nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.tar.zst nvim-treesitter-b8e3b03748e0c796648360417650302a826ada91.zip | |
fix(tiger): adjust invalid queries
Diffstat (limited to 'tests/query/highlights')
| -rw-r--r-- | tests/query/highlights/tiger/built-ins.tig | 6 | ||||
| -rw-r--r-- | tests/query/highlights/tiger/functions.tig | 6 | ||||
| -rw-r--r-- | tests/query/highlights/tiger/identifiers.tig | 4 | ||||
| -rw-r--r-- | tests/query/highlights/tiger/imports.tig | 2 | ||||
| -rw-r--r-- | tests/query/highlights/tiger/keywords.tig | 10 | ||||
| -rw-r--r-- | tests/query/highlights/tiger/object-oriented.tig | 4 |
6 files changed, 16 insertions, 16 deletions
diff --git a/tests/query/highlights/tiger/built-ins.tig b/tests/query/highlights/tiger/built-ins.tig index 68790541a..f359959fe 100644 --- a/tests/query/highlights/tiger/built-ins.tig +++ b/tests/query/highlights/tiger/built-ins.tig @@ -6,7 +6,7 @@ let /* ^ type.builtin */ var b := exit(0) - /* ^ function */ + /* ^ function.builtin */ type int = string /* Shadowing the built-in type */ /* ^ type.builtin */ @@ -30,13 +30,13 @@ in end; exit(1); - /* <- function */ + /* <- function.builtin */ print("shadowing is fun"); /* <- function.builtin */ self; - /* <- variable */ + /* <- variable.builtin */ b := print /* ^ variable */ diff --git a/tests/query/highlights/tiger/functions.tig b/tests/query/highlights/tiger/functions.tig index 802f394af..799ccd386 100644 --- a/tests/query/highlights/tiger/functions.tig +++ b/tests/query/highlights/tiger/functions.tig @@ -1,8 +1,8 @@ primitive print(s: string) /* ^ function */ -/* ^ variable.parameter */ +/* ^ parameter */ function func(a: int) : int = (print("Hello World!"); a) /* ^ function */ -/* ^ variable.parameter */ -/* ^ function */ +/* ^ parameter */ +/* ^ function.builtin */ diff --git a/tests/query/highlights/tiger/identifiers.tig b/tests/query/highlights/tiger/identifiers.tig index f177a5a5c..2d52edd14 100644 --- a/tests/query/highlights/tiger/identifiers.tig +++ b/tests/query/highlights/tiger/identifiers.tig @@ -22,8 +22,8 @@ var array := int_array[12] of 27; /* ^ type */ primitive func(a: int, b: string) : array -/* ^ variable.parameter */ +/* ^ parameter */ /* ^ type.builtin */ -/* ^ variable.parameter */ +/* ^ parameter */ /* ^ type.builtin */ /* ^ type */ diff --git a/tests/query/highlights/tiger/imports.tig b/tests/query/highlights/tiger/imports.tig index c056c301f..6e60910fb 100644 --- a/tests/query/highlights/tiger/imports.tig +++ b/tests/query/highlights/tiger/imports.tig @@ -1,3 +1,3 @@ import "lib.tih" /* <- keyword */ -/* ^ string.special.path */ +/* ^ string.special */ diff --git a/tests/query/highlights/tiger/keywords.tig b/tests/query/highlights/tiger/keywords.tig index 70cb82c05..79ebfd4d8 100644 --- a/tests/query/highlights/tiger/keywords.tig +++ b/tests/query/highlights/tiger/keywords.tig @@ -28,13 +28,13 @@ in /* ^ keyword */ for i := 12 to 27 do 42; - /* <- keyword.repeat */ - /* ^ keyword.repeat */ - /* ^ keyword.repeat */ + /* <- repeat */ + /* ^ repeat */ + /* ^ repeat */ while 12 do break - /* <- keyword.repeat */ - /* ^ keyword.repeat */ + /* <- repeat */ + /* ^ repeat */ /* ^ keyword */ end diff --git a/tests/query/highlights/tiger/object-oriented.tig b/tests/query/highlights/tiger/object-oriented.tig index 930eabf00..0b4357c02 100644 --- a/tests/query/highlights/tiger/object-oriented.tig +++ b/tests/query/highlights/tiger/object-oriented.tig @@ -12,13 +12,13 @@ let var a := 12 method meth() : int = self.a - /* <- keyword.method */ + /* <- method */ /* ^ method */ /* ^ variable.builtin */ } var object := new B - /* ^ keyword.constructor */ + /* ^ constructor */ in object.a := 27; /* ^ property */ |
