-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for Instance.new() in table values #836
Comments
Can you show the error you are experiencing, and create a minimal example that I can test with? But, this is looking like it might be a Luau issue. Do you also experience this in Roblox Studio? If so, I would recommend you report it to the Luau team directly |
Checked in Roblox Studio, and am getting a TypeError there as well. In Studio it appears as a warning, however, whereas in Luau LSP it appears as an error. Will raise the issue with the Luau team, thanks for your help. --!strict
type TestObj = {
model : Model?
}
local object : TestObj = {
model = nil
}
object.model = Instance.new("Model")
object.model.Parent = workspace Included the code if you're interested in taking a look. |
Luau-lsp currently does not update type based on instance.new type. Type is given in the string. When used in a new variable it works, but not when updating a table value.
The text was updated successfully, but these errors were encountered: