LuaLS / LuaLS/lua-language-server

[love-api] love.Data:clone() -> love.Data

Open Beginner friendly
#1,776 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Lua
Stars
4.4k
Forks
442
PR merge metrics
No merged PRs in 30d

Description

Currently love.Data:clone() returns love.Data, but love.Data is a superclass. That means if you clone love.ImageData, you will receive love.Data (not love.ImageData as expected). Use generics in this function annotation.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the love.Data:clone() function annotation in the love API definitions and inspect how related inheritance or generic annotations are expressed. Update the annotation so cloning a subtype such as love.ImageData preserves that subtype, then verify the resulting type information for the example described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
tooling
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
62/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.