LuaLS / LuaLS/lua-language-server
Syntax warning / error not flagged as such.
まだ誰も着手していません。
- 主要言語
- Lua
- スター
- 4.4k
- フォーク
- 442
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
### How are you using the lua-language-server?
Visual Studio Code Extension (sumneko.lua)
### Which OS are you using?
Windows
### What is the issue affecting?
Diagnostics/Syntax Checking
### Expected Behaviour
A warning or an error that the line in question is not complete, regardless of how the parser it's run in processes it:
```lua
local varA, varB functionCalledHere()
```
### Actual Behaviour
No warning or error was given, resulting in a 20 minute hunt for a `nil` in one of the variables that shouldn't exist. The plugin did not flag the line as having a syntax warning or error, even if the Lua engine did not have an issue with the code per se.
### Reproduction steps
.
### Additional Notes
Apologies for raising another issue, but I couldn't find any information on if this is a niche feature of Lua or a bug that just hadn't been fixed in `5.1`. But if it's not a feature and is an unintended side-effort, I feel like it should be raised as a warning by the LLS to alert the user like "hey, are you sure this is what you were intending to do" similar to variables lacking a `nil`.
### Log File
_No response_
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
Lua スニペット `local varA, varB functionCalledHere()` を使用して、Visual Studio Code 拡張機能で報告を再現します。まず、この不完全な宣言に対して構文診断がどのように生成されるかを追跡し、次にこのスニペットのリグレッションテストを追加して、診断なしではなく警告またはエラーが報告されることを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- lua
- 領域
- devtools
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 静か
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 48/100