Skip to content

style(career): reformat profile storage sources to match the original code style - #23

Merged
hzqst merged 1 commit into
mainfrom
style/career-storage-format
Oct 21, 2026
Merged

hzqst merged 1 commit into
mainfrom
style/career-storage-format

Conversation

@hzqst

@hzqst hzqst commented Oct 21, 2026

Copy link
Copy Markdown
Contributor

Summary

Layout-only cleanup of the Career profile storage code introduced in #22, so it matches the style of the existing sources in src/:

  • src/CareerProfileStorageHooks.cpp: one statement per line, blank lines between functions and logical blocks, wrapped long conditions and argument lists, one entry per row in EntryNames / patches / replacements, explicit braces on nested if/else, Boundary<T>(...) lambdas laid out so clang-format keeps them stable, and file-scope state grouped at the top (adds a CopyFn alias of the identical type).
  • src/CareerProfileStorage.cpp: expanded single-line ifs in NativeWriteAudit, braces on loop-nested ifs, blank lines between logical blocks.
  • src/CareerProfileStorage.h: split multi-variable declarations and separated member groups.
  • tests/career_profile_storage_tests.cpp: expanded one single-line if.

No identifiers, comments or behavior change.

Verification

  • Compiled the affected sources with the Release flags minus /GL before and after the change and compared dumpbin /disasm output (repeat builds of the same source were confirmed deterministic first):
    • CareerProfileStorage.obj, CareerProfileStorageHooks.obj, GameUI.obj: identical.
    • career_profile_storage_tests.obj: differs only in assert __LINE__ constants.
  • Release build of VGUI2Extension and tests succeeds; ctest -C Release: 8/8 passed.
  • VGUI2Extension-format-check: 66 files, 0 with differences.
  • Not run in game (the generated code is unchanged).

🤖 Generated with Claude Code

… code style

Layout-only cleanup of the Career profile storage code from #22: one
statement per line, blank lines between functions and logical blocks,
wrapped long conditions/argument lists, one entry per table row, and
explicit braces on nested control flow. No identifiers or comments change.

Verified with non-LTCG Release builds: the disassembly of
CareerProfileStorage.obj, CareerProfileStorageHooks.obj and GameUI.obj is
identical before and after; the test object differs only in assert line
numbers.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@hzqst
hzqst merged commit e00a161 into main Oct 21, 2026
3 checks passed
@hzqst
hzqst deleted the style/career-storage-format branch October 21, 2026 04:23
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