LuaLS / LuaLS/lua-language-server
@alias comments aren't visible
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- Lua
- Star
- 4.4k
- Fork
- 442
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
How are you using the lua-language-server?
Visual Studio Code Extension (sumneko.lua)
Which OS are you using?
Linux
What is the issue affecting?
Annotations, Hover
Expected Behaviour
a comment to an alias type should be shown as regular comment to a parameter would be shown (at least if there is no comment to the @param annotation itself). The hover message should read:
function f(arg: string)
@param arg — comment from alias
Unused functions.Lua Diagnostics.(unused-function)
Unused local `f`.Lua Diagnostics.(unused-local)
Actual Behaviour
the comment to the alias type isn't shown. the hover message is:
function f(arg: string)
Unused functions.Lua Diagnostics.(unused-function)
Unused local `f`.Lua Diagnostics.(unused-local)
Reproduction steps
- cat << EOF > file.lua
---@alias t_arg string comment from alias
---@param arg t_arg
local function f(arg)
end
EOF - code file.lua
- hover over the function name and read message
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Tái hiện vấn đề trong file.lua bằng các chú thích @alias và @param được hiển thị, sau đó kiểm tra điểm vào hover cho tài liệu hàm. Hoàn tất khi di chuột qua f bao gồm chú thích alias dưới dạng @param arg, đồng thời giữ nguyên các chẩn đoán hiện có và tôn trọng mọi chú thích @param tường minh.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- lua
- Lĩnh vực
- devtools
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 45/100