mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-20 20:30:05 -04:00
fix(python): regex injection not working for concatenated strings (#8197)
Co-authored-by: Riley Bruins <ribru17@hotmail.com>
This commit is contained in:
parent
98fe644cb3
commit
c53bb10a71
7 changed files with 83 additions and 3 deletions
11
tests/query/highlights/starlark/test.bzl
Normal file
11
tests/query/highlights/starlark/test.bzl
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
# split
|
||||
# ^ @comment
|
||||
assert_eq('foo bar'.split(' '), ['foo', 'bar'])
|
||||
# ^ @keyword
|
||||
# ^ @punctuation.bracket
|
||||
# ^ @string
|
||||
# ^ @punctuation.delimiter
|
||||
assert_eq('foo bar foo'.rsplit(' ', 1), ['foo bar', 'foo'])
|
||||
# ^ @number
|
||||
assert_eq("foo %s bar %d" % ("arg1", 2), "foo arg1 bar 2")
|
||||
# ^ @character
|
||||
Loading…
Add table
Add a link
Reference in a new issue