Skip to content

Add LuaCheck for static analysis #20

@refaim

Description

@refaim

Summary

Add LuaCheck to catch bugs and code quality issues via static analysis.

Motivation

LuaCheck can detect real bugs such as accidental globals, unused variables, and variable shadowing. Some of the recently fixed issues (closure bugs in hook loops, unsafe table modification during iteration) are the kind of problems that static analysis can catch early.

Plan

  1. Add a .luacheckrc with:
    • Lua 5.1 standard (WoW Lua version)
    • WoW API globals allowlist (there are community-maintained lists for this, e.g. from wow-declarations or wowless)
    • WIM-specific globals
  2. Fix or suppress any initial findings
  3. Document how to run it locally

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions