3 ms·
> but the syntax for external type declarations is undocumented https://luau-lang.org/typecheck https://luau-lang.org/typecheck https://luau-lang.org/grammar
by hipadev23 3y ago
> but the syntax for external type declarations is undocumented
https://luau-lang.org/typecheck https://luau-lang.org/typecheck
https://luau-lang.org/grammar https://luau-lang.org/grammar
- debugnik 3y agoThat's not it, I mean the "declare" statements that aren't even listed in the grammar, but are needed to give the type checker information about C API exports; I had to discover them by digging through source code. The analyzer even hardcodes a bunch of them. luau-lsp for example ships this globalTypes.d.lua file[1] for Roblox development and lets you configure your own. [1]: https://github.com/JohnnyMorganz/luau-lsp/blob/4b7872349d9b8803f514c1e61dc33b020ec25b80/scripts/globalTypes.d.lua https://github.com/JohnnyMorganz/luau-lsp/blob/4b7872349d9b8...