Skip to content

Annotation Refactor#35

Open
Pollux12 wants to merge 25 commits into
mainfrom
feat/annotation-refactor
Open

Annotation Refactor#35
Pollux12 wants to merge 25 commits into
mainfrom
feat/annotation-refactor

Conversation

@Pollux12

Copy link
Copy Markdown
Owner

This branch contains an overhaul for many previously hardcoded special Garry's Mod specific cases by moving it all to be annotation based rather than string based matches, alongside several bug fixes.

Pollux12 added 23 commits June 8, 2026 05:02
This gives an alternative to union and allows for increased precision without potentially noisy diagnostics as a result of that union. Rather than adding to a union, the language server can instead keep the generic type but register something as a potential default, so if not specified, it will use that value.
@mintlify

mintlify Bot commented Jun 12, 2026

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
GLuaLS 🟢 Ready View Preview Jun 12, 2026, 7:17 AM

💡 Tip: Enable Workflows to automatically generate PRs for you.

Pollux12 and others added 2 commits June 12, 2026 11:38
Three fixes found during review of the annotation refactor:

- perf: GmodClassMetadataIndex::add_call rebuilt the entire panel/skin
  cache on every re-add. Because scripted-class collection runs in both
  the pre- and post-analysis passes, every call was re-added once,
  making a full analysis O(calls * total_calls). Refresh only the
  re-added call's cache contribution incrementally instead.

- fix: the LS string-context arg->param conversion (adjusted_arg_index)
  adjusted on is_colon_call alone, diverging from the analyzer's
  param_idx_to_call_arg_idx for colon-defined methods (e.g.
  Entity:NetworkVar). Route all sites through one is_colon_define-aware
  helper so colon-called colon-defined functions resolve correctly.

- cleanup: drop redundant format!(...).to_string() in undefined_global.

Adds unit tests for the arg-index conversion (all four colon
combinations) and for incremental cache stability on re-add.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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