You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It looks like no possible to describe type of returned vararg
When I'm trying to do it editor highlight this type in orange color:
Looks like the orange color represents optional name of the returned variable.
Probably the most simple solution to this problem would be to check - if the name is "...", then it is vararg.
Like this:
And in my opinion, we don't need the @vararg tag at all. It would be simplier to use ---@param ... instead.
Sorry for oftopic, just want to share one last thought - I believe that decreasing number of ---@ tags when possible is always good idea, especially combining similar functionality. So I also think that we actually no need ---@field tag too!
Would be better to use ---@param tag for both - table fields and function arguments.
Thank you for taking the time to read this! 😺
The text was updated successfully, but these errors were encountered:
It looks like no possible to describe type of returned vararg
When I'm trying to do it editor highlight this type in orange color:
Looks like the orange color represents optional name of the returned variable.
Probably the most simple solution to this problem would be to check - if the name is "...", then it is vararg.
Like this:
And in my opinion, we don't need the
@vararg
tag at all. It would be simplier to use---@param ...
instead.Sorry for oftopic, just want to share one last thought - I believe that decreasing number of ---@ tags when possible is always good idea, especially combining similar functionality. So I also think that we actually no need
---@field
tag too!Would be better to use
---@param
tag for both - table fields and function arguments.Thank you for taking the time to read this! 😺
The text was updated successfully, but these errors were encountered: