Skip to content

fix(types): annotate config API - #1454

Open
oriori1703 wants to merge 1 commit into
L3MON4D3:masterfrom
oriori1703:fix/annotate-setup-alias
Open

oriori1703 wants to merge 1 commit into
L3MON4D3:masterfrom
oriori1703:fix/annotate-setup-alias

Conversation

@oriori1703

Copy link
Copy Markdown

Summary

  • explicitly type the forward-declared LuaSnip config API
  • prevent setup from being inferred as nullable by EmmyLua
  • retain the existing compatibility alias and runtime behavior

This is a narrow annotation workaround for EmmyLuaLs/emmylua-analyzer-rust#1272; the analyzer issue remains open.

Verification

  • real require('luasnip').setup {} consumer passes EmmyLua 0.25.1 and LuaLS 3.19.1
  • headless Neovim confirms setup and set_config remain the same function
  • StyLua and git diff --check pass

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant