Crafter.Build/tests/HouseRules
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jorijn van der Graaf 693e3c7af9 refactor(lint): enum-class asks the token stream, not a regex
The regex required the enum's name to follow `enum` on the same line, so a
declaration split over lines went unreported. Asking for the next token instead
makes the split and unsplit spellings read identically, and distinguishes the
`enum` KEYWORD from the same letters appearing elsewhere without needing word
boundaries to stand in for lexing.

Deliberately not moved to the AST, even though LintDecl already carries an exact
isScopedEnum. An AST is one configuration's slice, so a plain enum inside a
preprocessor branch inactive for the host would silently stop being reported;
tokens are lexed without evaluating #if, so every platform stays covered. Being
right about less is not an improvement here.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-31 00:21:12 +02:00
..
main.cpp refactor(lint): enum-class asks the token stream, not a regex 2026-07-31 00:21:12 +02:00