Replies: 2 comments 3 replies
-
If you put your code into a function and add a return after the I hope that can help in your use case. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Say I have something like this:
LuaLS complains that I've accessed

foo.bar
even thoughfoo
could benil
:But if I use the builtin

error
instead of mycustom_error
, LuaLS knows that this point cannot be reached whenfoo
isnil
:Is there a way to annotate
custom_error
so that LuaLS will know that it never returns, just like the builtinerror
?Beta Was this translation helpful? Give feedback.
All reactions