cfxlua-vscode icon indicating copy to clipboard operation
cfxlua-vscode copied to clipboard

in unpacking not fully supported

Open DokaDoka opened this issue 3 years ago • 1 comments

image

DokaDoka avatar Oct 10 '22 00:10 DokaDoka

~~For now I've replaced the whitespace check with space and tab; would require detecting and ignoring comments otherwise.~~

Proper detection of in syntax likely requires a real Lua parser rather than the basic pattern matching used right now; we need to ensure any instances of in aren't part of a comment, string, function, iterator, etc.

However in syntax has also been known to cause crashes* in the Lua runtime in some rare cases, and per the author of LuaGLM

Should probably avoid using any of the syntax extensions.

* Seemingly when failing to unpack the return value from a function? Can't quite remember. Safe navigation can lead to funny errors too.

thelindat avatar Oct 10 '22 01:10 thelindat