diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2022-06-15 15:36:03 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2022-06-15 15:36:03 +0800 |
commit | 96b4e0ba089c717aa5455a7f6fcf6caee863a74e (patch) | |
tree | e82bd7e57cf641d3e2a37892e7f5c892cab41bbf /changelog.md | |
parent | 98fe538e564bac10e5df65c31e20b8dc3317e87d (diff) | |
download | lua-language-server-96b4e0ba089c717aa5455a7f6fcf6caee863a74e.zip |
resolve #1094 infer type by `error`
Diffstat (limited to 'changelog.md')
-rw-r--r-- | changelog.md | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/changelog.md b/changelog.md index f2242e72..3b2e2dc0 100644 --- a/changelog.md +++ b/changelog.md @@ -8,6 +8,17 @@ if x == -- suggest `CONST.X` and `CONST.Y` here ``` +* `CHG` infer type by `error` + ```lua + ---@type integer? + local n + + if not n then + error('n is nil') + end + + print(n) -- `n` is `integer` here + ``` * `FIX` with clients that support LSP 3.17 (VSCode), workspace diagnostics are triggered every time when opening a file. * `FIX` [#1204](https://github.com/sumneko/lua-language-server/issues/1204) * `FIX` [#1208](https://github.com/sumneko/lua-language-server/issues/1208) |