kayler-renslow / arma-intellij-plugin

A plugin for Intellij IDEA that allows for syntactical analysis, code inspections, and other nifty features for the SQF scripting language in Arma 3.
MIT License
41 stars 9 forks source link

1.0.4 is kind of unusable #11

Closed BangL closed 8 years ago

BangL commented 8 years ago

i am using 1.0.4 for like 1 hour now, and... i just had to restart IDEA for the 5th time because it hangs/freezes for whole MINUTES randomly. sometimes when opening a file, sometimes when starting to edit one.

this never happened to me on 1.0.3, everything was fluent there.

BangL commented 8 years ago

i just double checked this:

its "okay" when you just edit one small file, but you can already reproduce this problem by just opening any sqf file which has more like 20 lines, and start editing the private-array.. when i have a few files open this freeze time stacks up to whole minutes as stated. and by saying "minutes" i am not even exaggerating.

kayler-renslow commented 8 years ago

Yea I know what the issue is and it has been the bane of my existence. Every single version has had this issue and I've always thrown something together to get rid of it just before release. This time, throwing something together is very hard. Thanks for reporting the issue though. :)

BangL commented 8 years ago

thats a bummer. could you explain the problem a bit, please?

kayler-renslow commented 8 years ago

It has to do with how the grammar is parsed. Right now for expression rules, it is evaluating huge chunks of text for each rule, realizing it's invalid, and going to the next expression rule only to do it again. The issue is very deep recursion what I assume to be occurring hundreds of times for a file.

kayler-renslow commented 8 years ago

Now that I've gotten some time to fiddle with the code, it appears it wasn't the grammar at all (which is very good news). It is the external annotator, which literally only checks to see if a variable is defined, used, and private. Lmao....

kayler-renslow commented 8 years ago

I fixed it! http://www.reactiongifs.com/wp-content/uploads/2013/12/partying.gif

BangL commented 8 years ago

1.0.4_1 runs pretty nice. the external annotator scan still scans forever, but i can live with that since its threaded now :+1: