Following #2670 (tools/check with jobj-flags + assert-macros), collecting
proposed checks and tooling so we can agree on shape before implementing each.
Comments on scope/shape welcome before any PR.
Tooling
Proposed checks
References
tools/flags — decomposes a literal into its bit-shifted flag set.
Open questions for maintainers
- Which checks should be blocking CI vs advisory?
- Preferred config format for
(function, param) → flagset?
- For the extern/literal pair: how do we reliably separate anti-pattern from
intentional cross-TU externs?
Following #2670 (
tools/checkwithjobj-flags+assert-macros), collectingproposed checks and tooling so we can agree on shape before implementing each.
Comments on scope/shape welcome before any PR.
Tooling
--fixmode — apply fixes locally (not CI).jobj-flagsis byte-safe;assert-macrosis best-effort (dev builds + verifies,@todos stragglers).Dry-run diff by default. (suggested by @ribbanya)
(function name, parameter index) → flag set, resolving raw literals (incl. composite masks, via bit-shiftdecomposition like
tools/flags) to the named flags. Subsumesjobj-flags.Proposed checks
HSD_JObj*Flags*resolvable tonamed
JOBJ_*flags (generalizes the current0x10→JOBJ_HIDDENcheck).Fighter_ChangeMotionStatecalls — rawliterals → named flags.
to distinguish de-inlining anti-patterns from legit cross-TU pool-sharing
externs (e.g. zako matches ftcoattack100 #2666
extern f32 ftCo_804D90D0), or it false-positives.same contextual caveat.
References
tools/flags— decomposes a literal into its bit-shifted flag set.Open questions for maintainers
(function, param) → flagset?intentional cross-TU externs?