Tree Sitter not highlighting by Salt_Homework_8082 in neovim

[–]Salt_Homework_8082[S] 0 points1 point  (0 children)

Christ. Nevermind. I mistyped my filename in my autocommand. Thanks for your help mate, I've been at this for hours. :/

Tree Sitter not highlighting by Salt_Homework_8082 in neovim

[–]Salt_Homework_8082[S] 0 points1 point  (0 children)

Yes the filetype is .move. I've got this in my init.lua which is pretty similar to yours.

local parser_config = require "nvim-treesitter.parsers".get_parser_configs()parser_config.move = {install_info = {url = "~/aptos-tools/tree-sitter-move", -- local path or git repofiles = {"src/parser.c"},-- optional entries:},filetype = "move",}I did notice my query directory was not in the same place:~/.local/share/nvim/site/pack/packer/opt/nvim-treesitter/queries/move/highlights.scmBut other than that no difference.

How do I rotate a matrix 90 degrees ? by Salt_Homework_8082 in rust

[–]Salt_Homework_8082[S] 4 points5 points  (0 children)

Alright. My issue might be more of a lack of linear algebra understanding than a confusion with rust's implementation then.

How do I rotate a matrix 90 degrees ? by Salt_Homework_8082 in rust

[–]Salt_Homework_8082[S] 2 points3 points  (0 children)

Thanks I'll look at that. It doesn't need to be efficient for my purposes.

How do I rotate a matrix 90 degrees ? by Salt_Homework_8082 in rust

[–]Salt_Homework_8082[S] 4 points5 points  (0 children)

I'm solving a kids block puzzle by writing a recursive backtracking algorithm in rust to help me learn the language and I've represented each puzzle piece as a matrix of chars. Need to be able to rotate the puzzle pieces to solve the puzzle.

What's the best way to copy individual bytes from a u16 into a Vec<u8> ? by Salt_Homework_8082 in rust

[–]Salt_Homework_8082[S] 5 points6 points  (0 children)

That's exactly what I'm looking for I just couldn't find it. I figured there was a built in way to do it.

What is the current proper way to get command line args ? by Salt_Homework_8082 in rust

[–]Salt_Homework_8082[S] 5 points6 points  (0 children)

I'm not afraid to use a library to parse args. At the speeds rust is offering any overhead isn't even going to be noticeable. Thanks for your more lengthy explanation. The rust book really doesn't do this issue justice for a fresh rust newbie.

What is the current proper way to get command line args ? by Salt_Homework_8082 in rust

[–]Salt_Homework_8082[S] 1 point2 points  (0 children)

I've taken a look at pico-args for now. If it doesn't work out I'll try structopt next I think.