diff options
| author | Amaan Qureshi <amaanq12@gmail.com> | 2023-03-09 19:58:04 -0500 |
|---|---|---|
| committer | Amaan Qureshi <amaanq12@gmail.com> | 2023-03-10 03:38:23 -0500 |
| commit | ffa6efa7f55e88be72812c47e4286fda48ab94f0 (patch) | |
| tree | fabff796afd6f890bb5c8af9331e0883bdc72c2c /tests/query/highlights/julia | |
| parent | feat(julia): add builtin functions & types (diff) | |
| download | nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.tar nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.tar.gz nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.tar.bz2 nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.tar.lz nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.tar.xz nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.tar.zst nvim-treesitter-ffa6efa7f55e88be72812c47e4286fda48ab94f0.zip | |
feat(julia): add tests for new changes
Diffstat (limited to 'tests/query/highlights/julia')
| -rw-r--r-- | tests/query/highlights/julia/test.jl | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/query/highlights/julia/test.jl b/tests/query/highlights/julia/test.jl new file mode 100644 index 000000000..46fc313c0 --- /dev/null +++ b/tests/query/highlights/julia/test.jl @@ -0,0 +1,26 @@ +function load_data(::Symbol; ::Int) :: Tuple +# <- keyword.function +# ^ function +# ^ punctuation.bracket +# ^^ punctuation.delimiter +# ^ type.builtin +# ^ punctuation.delimiter +# ^^ punctuation.delimiter +# ^^^ type.builtin +# ^ punctuation.bracket +# ^^ punctuation.delimiter +# ^ type.builtin + dataset = CIFAR10(; Tx = Float32, split = split) +# ^^^^^^^ variable +# ^ operator +# ^ function.call +# ^ operator +# ^ type.builtin + X = reshape(dataset.features[:, :, :, begin:n_obs], :, n_obs) # flattening the image pixels +# ^^^^^ variable.builtin + y = categorical2onehot(dataset.targets[begin:n_obs], N_LABELS) +# ^^^^^ variable.builtin + return X, y +# ^^^^^^ keyword.return +end +# <- keyword.function |
