nvim-treesitter/tests/query/highlights/python/functions.py

21 lines
390 B
Python
Raw Normal View History

2025-03-11 19:41:58 +01:00
def func() -> None: ...
_ = func()
2025-03-11 19:46:53 +01:00
# ^^^^ @function.call
2025-03-11 19:41:58 +01:00
2025-03-11 19:57:53 +01:00
"{}".format(1)
2025-03-11 19:59:57 +01:00
# ^^^^^^ @function.method.call
2025-03-11 19:57:53 +01:00
2025-03-11 19:41:58 +01:00
class Foo:
def method(self) -> None: ...
Foo().method()
# ^^^^^^ @function.method.call
2025-03-11 19:50:59 +01:00
@pytest.mark.filterwarnings("ignore::DeprecationWarning")
#^^^^^^ @variable
# ^^^^ @variable.member
# ^^^^^^^^^^^^^^ @function.method.call
def test_func():
pass