Intellisense is broken in the most recent studio version. Specifically, iterating through any element (string, table, etc.) completely loses it’s intellisense inside of function calls. I’ve attached a gif and some code snippets with comments pertaining to the issue.
https://gyazo.com/e73bb5b5cb20cc0434d1215fea118cfa
local v: {string} = {"derp", "herp", "flerp"}
for _, d in v do
print(d:) -- no intellisense appears, when it should.
end
A workaround is this:
local v: {string} = {"derp", "herp", "flerp"}
for _, d in v do
local d: string = d
print(d:) -- intellisense now appears, as the value is interpreted as a string
end
The original snippet was working, with the correct intellisense, up until yesterday. I’ve asked around and everyone I’ve talked to is also experiencing this issue.
System Information:
Ryzen 7 7800x3D
64GB DDR4 6000MHz
NVIDIA GeForce RTX 4080
Beta Features:
- CreateAssetAsync Lua API
- Dragger QoL Improvements
Reproduction steps:
- Create a new place file.
- Create a script.
- Place this snippet inside of the script:
local v: {string} = {"derp", "herp", "flerp"}
for _, d in v do
print(d:) -- no intellisense appears, when it should.
end
- Mess around with variable ‘d’-- delete and re-add the colon, you’ll see there is no intellisense.
The example I’ve provided uses strings, but you can test this with any data type. Another good example is an array of tables-- you cannot access the properties of each element inside of a function call, like print
.
Expected behavior
Elements inside of function calls should have intellisense, like normal. The attached workaround shows the intended behavior-- intellisense is interpreting the element as expected.
local v: {string} = {"derp", "herp", "flerp"}
for _, d in v do
local d: string = d
print(d:) -- intellisense now appears, as the value is interpreted as a string
end