aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorCaleb White <cdwhite3@pm.me>2024-03-18 22:42:44 -0500
committerChristian Clason <c.clason@uni-graz.at>2024-03-27 08:29:44 +0100
commit7d938c1c72ac21cd059ed9a71d50f1329b33d988 (patch)
treec4a241a1f4222ad240fd73341eff241c858caefb /tests
parentfix(php): add missing keyword highlights, fix static keyword (diff)
downloadnvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.tar
nvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.tar.gz
nvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.tar.bz2
nvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.tar.lz
nvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.tar.xz
nvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.tar.zst
nvim-treesitter-7d938c1c72ac21cd059ed9a71d50f1329b33d988.zip
fix(php): fix use_{as,instead_of}_clause highlights
Diffstat (limited to 'tests')
-rw-r--r--tests/query/highlights/php/keywords.php17
1 files changed, 14 insertions, 3 deletions
diff --git a/tests/query/highlights/php/keywords.php b/tests/query/highlights/php/keywords.php
index e11a9f351..4bacf1c9d 100644
--- a/tests/query/highlights/php/keywords.php
+++ b/tests/query/highlights/php/keywords.php
@@ -96,9 +96,20 @@ class B extends A implements T
U::small insteadof T;
// ^ @type
// ^^ @operator
-// ^^^^^ @constant
+// ^^^^^ @function.method
// ^^^^^^^^^ @keyword
// ^ @type
+ T::big as protected tBig;
+// ^ @type
+// ^^^ @function.method
+// ^^ @keyword.operator
+// ^^^^^^^^^ @keyword.modifier
+// ^^^^ @function.method
+ big as private tBig;
+// ^^^ @function.method
+// ^^ @keyword.operator
+// ^^^^^^^^^ @keyword.modifier
+// ^^^^ @function.method
}
public function foo(callable $call): self
// ^^^^^^^^ @type.builtin
@@ -106,7 +117,7 @@ class B extends A implements T
{
$call instanceof Closure;
// ^^^^^ @variable
-// ^^^^^^^^^^ @keyword
+// ^^^^^^^^^^ @keyword.operator
// ^^^^^^^ @type
fn ($a, $b) => $a + $b;
// ^^ @keyword.function
@@ -147,7 +158,7 @@ class B extends A implements T
print("a");
// ^^^^^ @keyword
exit;
-// ^^^^ @keyword
+// ^^^^ @keyword.return
exit();
// ^^^^ @function.builtin
exit(1);