lua-language-server icon indicating copy to clipboard operation
lua-language-server copied to clipboard

能否支持 类似 python 的 import 的模块类型?

Open zzyAZU opened this issue 1 year ago • 0 comments

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?

Annotations

Expected Behaviour

能否支持 类似 python 的 import 的模块类型?

例如: a.lua 内容如下 a = 1 b = 'hello' function c() end

b.lua 内容如下 local m = import('a.lua') print(m.a) print(m.b) m.c()

其中 在 b.lua 中 m.a m.b m.c 都可以被正确识别出正确的类型

Actual Behaviour

例如: a.lua 内容如下 a = 1 b = 'hello' function c() end

b.lua 内容如下 local m = import('a.lua') print(m.a) print(m.b) m.c()

其中 在 b.lua 中 m.a m.b m.c 都可以被正确识别出正确的类型

Reproduction steps

例如: a.lua 内容如下 a = 1 b = 'hello' function c() end

b.lua 内容如下 local m = import('a.lua') print(m.a) print(m.b) m.c()

其中 在 b.lua 中 m.a m.b m.c 都可以被正确识别出正确的类型

Additional Notes

No response

Log File

No response

zzyAZU avatar May 15 '24 03:05 zzyAZU