Repository navigation
Agent docs: Warcraft III runtime facts and corrected test guidance - #1370
Conversation
…id recycler's comment The test Lua is stock 5.3 with every library, so executing the script cannot notice a helper that reaches for debug or collectgarbage. The recycler hands out the most recently freed id first; its comment claimed the opposite.
…est guidance Adds docs/WC3_RUNTIME.md and AGENTS.md section 11, a sibling-project list, and a CLAUDE.md that imports AGENTS.md. Corrects claims the code contradicts (testLua replaces the interpreter runs, wurstMod does not exist, the locals spill starts at 200, luac missing fails). Drops generic and historical lines.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 22e34cb5ad
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…nt-knowledge-12095f
…ce goal, Lua parity shim Adds the repo-wide rules to fix defects where they originate and to keep the compiler deterministic, an orientation on the old and new generic systems, the performance goal and the purpose of the Lua shim. Drops the KeyedMap text that duplicated WURST_LANGUAGE.md. Records two open questions in BACKLOG.md: auditing the remaining Lua emission, and the shape of the generated AST.
Natives are only emitted when a program refers to them, so the single-fixture test could not see testSuccess's os.exit. A second test enumerates LuaNatives and exempts testSuccess explicitly. Docs also record why Lua real == stays exact.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8152ddea15
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Natives, old-generics fallbacks and other helpers are emitted only on demand, so guarding one fixture and then one registry left gaps. Every emitted byte starts as a literal under translation/, so the test scans those and exempts only the testSuccess shim. Removes the LuaNatives accessor the previous test needed.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e18946d7a1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
… class ImTranslator.buildClassPartitions unions each class with its superclasses and gives the group one ClassManagementVars, so siblings and the base class share ids and the cap.
…ned' LuaTranslator.translateFunc emits __wurst_-prefixed natives directly and wraps the rest in a definition guard.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 50f8efab98
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…races and callbacks The test Lua is 5.3 on Windows and the Linux CI but its version is never checked. Stack-trace bookkeeping applies to instrumented functions, not every call. The literal-scan guard counts a banned name anywhere, inside strings and comments too, since a string can be run with load.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1c80641245
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
The literal scan exempted any os.exit() literal in LuaNatives.java, so a second native emitting it would have passed. It now tracks the addNative(...) line a literal belongs to.
|
@codex review |
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Adds
docs/WC3_RUNTIME.mdand AGENTS.md section 11 on what the game does that the code, the interpreter and the tests do not show: Wurst has no garbage collector, the game's Lua is not the test Lua, nothing optimises the emitted script at run time, and Lua tables must not be iterated in an observable order. Each fact says whether it was measured, follows from the code, or is community-reported.Repo-wide rules in AGENTS.md:
DeterministicChecksfrom Make compilation order deterministic #1366)<T>and new<T:>generic systemsAlso:
CLAUDE.mdthat imports AGENTS.mdtestLua(true)replaces the interpreter runs,wurstModdoes not exist, the locals spill starts at 200, a missingluacfails a testAllTests.xmlline replacedRecycleCodeGeneratorQueue's comment said the opposite of the code: the free list is a stack, so a freed id comes back firstBACKLOG.md: auditing the remaining Lua emission, and the shape of the generated ASTNew test
LuaTranslationTests.emittedLuaUsesOnlyLibrariesTheGameProvidesfails if emitted Lua usesdebug,collectgarbage,io,os,packageorrequire. Checked by making the backend emit them: it fails, and passes once reverted.