Skip to content

code_health: test-case check reads brace-initialized fields - #670

Merged
dayfine merged 1 commit into
agentsfrom
agents-testcase-init-lint
Nov 19, 2026
Merged

dayfine merged 1 commit into
agentsfrom
agents-testcase-init-lint

Conversation

@dayfine

@dayfine dayfine commented Nov 19, 2026

Copy link
Copy Markdown
Owner

The test-case check failed any case struct whose fields were written std::string name = {}; or Input input{};, because the statement splitter cuts those at the { and the field reader only looked at ;-ended statements. That forced #667 and #648 to leave name/input/expectation bare, against the Windows clang = {} rule. The field reader now also takes brace-initialized fields. Added a contract test (value-initialized case passes, a name in the input still fails); the code_health suite passes, and the ScreenEventsCase and RangeCase files pass with = {} added while a copy with a field removed still fails.

The statement splitter cuts `std::string name = {};` at its `{`, so
structures() never saw the field and the test-case check failed every
case struct that follows the `= {}` rule for Windows clang.
@dayfine
dayfine marked this pull request as ready for review November 19, 2026 06:19
@dayfine
dayfine merged commit abdb4ca into agents Nov 19, 2026
1 check passed
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