-
-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Majoring stuttering in Zig files #102
Comments
Can you please provide a sample file where the stutter occurs? There is a test file |
The stuttering happens even in a simple |
Oh, so it only happens in insert mode? Yes, I can replicate that. I just never noticed because I never write Zig, I was just looking at the highlighting. That's an interesting problem, I am not sure how to profile the Lua code. There is |
Sorry for the delay! Please let me know if there's anything I can do or test on my end to help the debugging process. I'm not very familiar with the lua internals or where to go for profiling but I'd be happy to test anything you come up with! |
Sorry, I am quite busy at the moment and this issue is rather low on the list of priorities. For the time being you should blacklist Zig until I get around to debugging the issue. |
all good, no worries! I will do just that.
…On Sun, Mar 17, 2024 at 4:21 PM Alejandro Sanchez ***@***.***> wrote:
Sorry, I am quite busy at the moment and this issue is rather low on the
list of priorities. For the time being you should blacklist Zig until I get
around to debugging the issue.
—
Reply to this email directly, view it on GitHub
<#102 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AQQDEKZAR23OPLYSKZIY2NTYYYQPNAVCNFSM6AAAAABEIR5DGSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMBSGY2TINBYGA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Great plugin, I use this zig-webui for testing, it will stuck a little while, |
I'll go through the code and try to fix it |
I have also been experiencing this bug with zig, other languages run fine (or at least C, Lua and Rust do). |
There have been updates to the Zig parser and I have just pushed an updated query to |
From my very brief testing the issue seems to be completely fixed!! Thank you so much. Your effort and this awesome plugin does not go underappreciated 🙏 I'll leave the issue open for a tad bit longer just in case any more issues come up. |
Thank you for your kind words, but I did not actually do anything other than just rename the patterns to fit the updated parser. There was probably some inefficiency in the parser itself and we got the performance fix for free with the updated. I had updated the nvim-treesitter version that's used for testing and then I saw a bunch of errors in the Zig query because the pattern names had changed. So after fixing the names I got curious and tried editing the sample file, and it turned out that the stuttering was gone on its own. (the real lesson learned here is the value of automated testing) |
I kinda figured as much, but my point remains with regards to your effort maintaining this plugin. Either way glad it seems to be fixed :P |
Neovim version
0.9.4
Language affected
Zig
Query
rainbow-delimiters
Strategy
No response
Description
Hey, firstly thanks for the awesome plugin!
I've been having unbearably long stutters in Zig files only. Changing the strategy from global to local only made the performance hit maybe slightly worse. I have also tried disabling/blacklisting
comment
as suggested in #53, to no avail. The size of the file does not seem to matter either (it happens in tiny files too), and I have been unable to replicate it in any other filetype. It's strange.. like every 1-2 seconds neovim freezes entirely for a second and then resumes. I'm happy to record a video or do some debugging if it's helpful! Thanks.The text was updated successfully, but these errors were encountered: