Skip to content

Use one type for listed local variables #2051

@RomanSpector

Description

@RomanSpector

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?

Type Checking

Expected Behaviour

t2 and t4 is expected to be defined as Test

Actual Behaviour

image

image

image

image

Reproduction steps

---@alias Test
---|test1
---|test2

---@type Test
local t1, t2;

local t3, t4; ---@type Test

Additional Notes

No response

Log File

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionUser has a question

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions